Utter Basics
Let's show the actual guts of a web page:
<html>
<head>
<title>My First Web Page :0)</title>
</head>
<body>
My First Web Page!<br>
</body>
</html>
|
That is a Web Page! Told ya it was simple! So, take a look at it. See the <title> and </title>? Call this start title and end title, just as we did before with the <center> tag. It's very important to think of the tags this way. Start and End. Here we've given our page a title with a smiley face at the end of it.
The title is important, don't forget it. When you get going and your pages show up on search engines, it is this title that will be the name of your page in the search results. This is also what shows up at the very top of your browser when viewing the page. Also, when you bookmark your page this is what will show in the bookmark files. Leave this field blank and you'll have a blank bookmark and blank entry on the search engines! That's not much good is it?
Make a new title for each page in your site so that it reflects the content of each page rather than simply the general name of the entire web site itself. Note the titles on these pages. I've changed each one to reflect what each individual page is about, rather than just calling them all Night Train Web Productions HTML Tutor. Be as descriptive as you can, in as few words as you can.
As you see HTML is orderly. First off we tell the browser that this page is an HTML document with the tag <html> without this tag the browser won't display your page as an HTML Web Page. When the entire page is done we tell the browser that the HTML coding is complete and the page is ended with the </html> tag. That's the last code on the page.
Next we give the browser a <head> tag. Between the <head> and </head> is the <title> and </title>. Begin title and end title.
Next, with the <body> tag, we tell the browser that the body of our HTML document starts here. In this simple demonstration there is only one line of text to our page, then we move on to end the body area of our HTML document with the </body> tag.
Finally we finish the page by telling the browser that there is no more HTML and our page ends here with </html>.
I want to stress this: All the tags start <> and end </>. You need to think start and end for each code.
Now that I have said that ... I lied. Well ... sort of anyway. Think of all code that way and you'll be right. The <br /> is an exception. For this tutor we'll always be coding the forced line break this way. There is no second half or end for this tag, so the / tells the browser that this tag is finished right here.
So ... we've made a web page. But ... there is nothing but a few words in it. So let's move on and take a closer look at the <body> tag.
It's time for your second quiz.
<
Previous: Basic Code
—
Next: The Body Tag >
|