Читать книгу CoderDojo: My First Website - Clyde Hatter - Страница 11

Оглавление

5. After it’s reloaded, the page looks a little different. That’s because the words are now displaying in a sans-serif font – that’s what font-family: sans-serif; does in the stylesheet.

A sans-serif font looks like this

A serif font looks like this

About Us

We are the Nanonauts.

Our names are Holy, Dervla, Daniel and Sam.

About Us

We are the Nanonauts.

Our names are Holly, Dervla, Daniel and Sam.

CONGRATULATIONS!

YOU’VE MADE A WEB PAGE AND A STYLESHEET – AND THEY’RE WORKING TOGETHER!

THINGS TO DO NEXT

Enter some more paragraphs of text. Paragraphs go between the <p> and </p> tags. Like this:

<p>I am learning how to make a website for my Dojo Nano.</p>

<p> is a start tag. </p> is an end tag. Can you spot the difference?

You can see now that a web page is just text typed into a text file. How the text appears on the web page is controlled by the tags. What happens if you use h1 or h2 tags instead of p tags? What happens if you put some words inside strong?

Like this:

<p>My name is <strong>Sam</strong></p>

CoderDojo: My First Website

Подняться наверх