HTML and CSS Reference
In-Depth Information
The following sections drill into each of the document structuring markup elements and
explore what's contained inside.
The Document Head
The information in the head element of an (X)HTML document is very important because it
is used to describe or augment the content of the document. The element acts like the front
matter or cover page of a document. In many cases, the information contained within the
head element is information about the page that is useful for visual styling, defining
interactivity, setting the page title, and providing other useful information that describes or
controls the document.
The title Element
A single title element is required in the head element and is used to set the text that most
browsers display in their title bar. The value within a title is also used in a browser's
history system, recorded when the page is bookmarked, and consulted by search engine
robots to help determine page meaning. In short, it is pretty important to have a
syntactically correct, descriptive, and appropriate page title. Thus, given
<title> Simple HTML Title Example </title>
you will see something like this:
When a title is not specified, most browsers display the URL path or filename instead:
Only one title element should appear in every document, and most user agents will
ignore subsequent tag instances. You should be quite careful about making sure a title
element is well formed because omitting the close tag can cause many browsers to not load
the document. A recent version of Opera reveals what is likely happening in this situation:
Here it appears that the markup and rest of the document are used as the contents of the
unclosed title element, and thus nothing is rendered in the browser. It should be noted that
this particular rendering may vary because some browsers fix an unclosed title.
Search WWH ::




Custom Search