The sections in an HTML document.
A web browser knows it is interpretting a web pgae because it starts with the <html> tag.
Every HTML document (web page) should start with the <html> tag and end with the matching </html> tag. This tells the web browser to start and end interpretting HTML tags.
Anything before or after the <html> pair is supposed to be interpretted as plain ordinary text (with all HTML tags being printed just like they appear in the source). Browsers that support Java, J++, or JavaScript can interpret each of those languages through special indications.
Just to be confusing, some browsers might sometimes interpret HTML tags before of the <html> pair. And some browsers will keep on interpretting HTML tags after the <html> ending tag. Those are both non-standard behaviors. With the exception of Java, J++, and JavaScript, you should avoid putting anything other than comments outside of the <html> tag pair.
Leaving off the trailing </html> tag is a mistake, but rarely causes any problems. It is good practice to always put in the trailing </html> tag, but sometimes you cant, such as when using some CGI guest book scripts.
An HTML document has two sections: a head and a body.
The head section should start with the <head> tag and end with the matching </head> tag.
The head section contains general information about the web page, such as its title.
The body section should start with the <body> tag and end with the matching </body> tag.
The body section contains the web page that is presented in the browser.
| previous article | return to Web | next article |
Copyright © 1998 Milo (except as otherwise noted) All rights reserved.
This site made on Macintosh computers.
Best viewed with Netscape Navigator on an Apple
Macintosh
.
No Microsoft products used in the preparation of this web site.
updated March 27, 1998 C.E. © 1998 Milo
| Electric Emperor |