The standard structure of an HTML page is quite simple. The document is contained within <html> </html> tags. The HTML document is then divided into two sections, the head and body elements respectively. The <head> </head> tags contain header information for the document. This header information normally contains a title tag titling the document, meta tags describing the document, link tags normally used to include CSS, and script tags normally used to load external JavaScript. No elements contained in the header are actually displayed on the web page (the title is display in the titlebar of the browser window) and there should be no text beyond that of a new line or space.
The body tag is used to contain all that is displayed in the document itself (a browser viewport). The content and text of the document is contained within the body, and the header is used to describe, alter or compliment that content.
The basic structure of an HTML document is shown below:
<!-- Basic HTML Document Structure --> <html> <head> <title></title> </head> <body> </body> </html>
Whilst the above will work well in many instances, it is sometimes useful to prepend a Document Type (DOCTYPE) header, and specify the language (lang) attribute, this adds more of a meta description to the page, and allows the browser to render the document in various ways, and perhaps spell check if it knows the language to be used.
An HTML page structure with meta information is shown below:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional //EN" "http://www.w3.org/TR/html4/loose.dtd"> <html lang = "en"> <head> <title></title> </head> <body> </body> </html>
Framesets have perhaps fallen out of vogue over the years. The reason is they don't allow a document to exist as a unit, this has implication for search engines, and certain advanced techniques. But, the frameset paradigm is quite a powerful one; it allows for a modular style of development, a persistant interface in part, and reduces total download size.
The head structure remains the same, but the body structure is replaced with frameset. The doctype is altered as well. Each document is introduced via the src (source) attribute of the frame tag. A basic frameset structure is shown below:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd"> <html> <head> <title></title> </head> <frameset cols = "200, *"> <frame src = "document1"></frame> <frame src = "document2"></frame> <noframes> </noframes> </frameset> </html>
Bookmark and then activate Concept Visor to comment on this page, or any other page on the web. The Concept Visor also allows you to view comments made on the page.
If you have found this site useful please consider linking to it @ http://html.poisedsolutions.com/
© Copyright Poised Solutions 2008 All Rights Reserved
Site Designed & Developed by
Poised Solutions
If you wish to discuss hiring Poised Solutions for an
information technology (IT project please get in contact
or visit the main PoisedSolutions IT Consultancy Website.
Poised Solutions is based in the Thames Valley area of the UK.