Try It: Add Code
In your brand new file, add the code above. Look at your file in a browser. It should be blank.
Every HTML page should begin with the
<html> tag. It
tells the browser that the HTML is starting.
Likewise, the matching end tag,
</html> tells the browser
the HTML is ending. Some browsers will not display any text that appears before
<html> tag or after the
<head>tag and the
<body>tags always go inside the
<html>tag. Notice how the
<head>tag ends before the
<body>tag begins. As you can see in the diagram, all three of these tags are container tags: they have a start tag and an end tag.
Try adding the
<title>tag to your file. Reload your page to see your title appear.
<title>tag is an example of a tag that goes in the
<head>and only there, never in the
<body>. This is because it describes something about the page (the title) rather than appearing in the page itself.
other tags you've learned so far,
a container tag. The text you put between the start tag and the end
tag is what the browser uses as the title of the window displaying