HEAD
The HEAD element has no attributes and the start and end tag can alwaysbe safely omitted as they can be readily inferred by the parser.Information in the HEAD element corresponds to the top part of a memoor mail message. It describes properties of the document such as thetitle, the document toolbar, and additional meta-information. There isno intended significance to the order of elements in the document head.Note that the TITLE element is always required. In fact, the minimalHTML 3.0 document consists of the TITLE element alone!Within the HEAD element, only certain elements are allowed.Information in the HEAD element may include the following elements(arranged alphabetically):
BASE
The BASE element allows the URL of the document itself to berecorded in situations in which the document may be read out ofcontext. URLs within the document may be in a "partial" form relativeto this base address. The default base address is the URL used toretrieve the document.
For example:
<base href="http://acme.com/docs/mydoc.html"> ... <img src="images/me.gif">
which resolves to "http://acme.com/docs/images/me.gif".
ISINDEX
The ISINDEX element informs the HTML user agent that the document isan index document. As well as reading it, the reader may use a keywordsearch.
The document can be queried with a keyword search by adding aquestion mark to the end of the document address, followed by a list ofkeywords separated by plus signs. See the network address format formore information.
Note: A server normally generates the ISINDEX tagautomatically. If added by hand to an HTML document, the browserassumes that the server can handle a search on the document. Obviouslythe server must have this capability for it to work: simply adding<ISINDEX> in the document is not enough to make searches happenif the server does not have a search engine!
Example:
<ISINDEX>
The URL used for processing queries can be overridden with the HREFattribute. You can also use the PROMPT attribute to change the defaultprompt supplied by the browser, e.g.
<ISINDEX HREF="phone.db" PROMPT="Enter Surname:">
LINK
The LINK element indicates a relationship between the document andsome other object. A document may have any number of LINK elements. TheLINK element is empty (does not have a closing tag), but takes the sameattributes as the anchor element. The important attributes are:
- REL
- This defines the relationship defined by the link.
- REV
- This defines a reverse relationship. A link from document Ato document B with REV=relation expresses the same relationshipas a link from B to A with REL=relation. REV=made is sometimesused to identify the document author, either the author's email addresswith a mailto URI, or a link to the author's home page.
- HREF
- This names an object using the URInotation.
Using LINK to define document specific toolbars
An important use of the LINK element is to define a toolbar ofnavigation buttons or an equivalent mechanism such as menu items.
LINK relationship values reserved for toolbars are:
- REL=Home
- The link references a home page or the top of somehierarchy.
- REL=ToC
- The link references a document servingas a table of contents.
- REL=Index
- The link references adocument providing an index for the current document.
- REL=Glossary
- The link references a document providing a glossaryof terms that pertain to the current document.
- REL=Copyright
- The link references a copyright statement forthe current document.
- REL=Up
- When the document forms part of a hierarchy, this linkreferences the immediate parent of the current document.
- REL=Next
- The link references the next document to visit in aguided tour.
- REL=Previous
- The link references the previous document in aguided tour.
- REL=Help
- The link references a document offering help, e.g.describing the wider context and offering further links to relevantdocuments. This is aimed at reorienting users who have lost their way.
- REL=Bookmark
- Bookmarks are used to provide directlinks to key entry points into an extended document. The TITLEattribute may be used to label the bookmark. Several bookmarks may bedefined in each document, and provide a means for orienting users inextended documents.
An example of toolbar LINK elements:
<LINK REL=Previous HREF=doc31.html> <LINK REL=Next HREF=doc33.html> <LINK REL=Bookmark TITLE="Order Form" HREF=doc56.html>
Using LINK to include a Document Banner
The LINK element can be used with REL=Banner to reference anotherdocument to be used as banner for this document. This is typicallyused for corporate logos, navigation aids, and other information whichshouldn't be scrolled with the rest of the document.For example:<LINK REL=Banner HREF=banner.html>
The use of a LINK element in this way, allows a banner to be sharedbetween several documents, with the benefit of being able to separatelycache the banner. Rather than using a linked banner, you can also includethe banner in the document itself, using theBANNER element.
Link to an associated Style Sheet
The LINK element can be used with REL=StyleSheet to reference a stylesheet to be used to control the way the current document is rendered.For example:<LINK REL=StyleSheet HREF=housestyle.dsssl>
Other uses of the LINK element
Additional relationship names have been proposed, but do not formpart of this specification. Servers may also allow links to be added bythose who do not have the right to alter the body of a document.
META
The META element is used within the HEAD element to embed documentmeta-information not defined by other HTML elements. Such informationcan be extracted by servers/clients for use in identifying, indexingand cataloging specialized document meta-information.
Although it is generally preferable to used named elements that havewell defined semantics for each type of meta-information, such astitle, this element is provided for situations where strict SGMLparsing is necessary and the local DTD is not extensible.
In addition, HTTP servers can read the contents of the document headto generate response headers corresponding to any elements defining avalue for the attribute HTTP-EQUIV. This provides document authors witha mechanism (not necessarily the preferred one) for identifyinginformation that should be included in the response headers of an HTTPrequest.
The META element has three attributes:
- NAME
- Used to name a property such as author, publicationdate etc. If absent, the name can be assumed to be the same as thevalue of HTTP-EQUIV.
- CONTENT
- Used to supply a value for a named property.
- HTTP-EQUIV
- This attribute binds the element to anHTTP response header. If the semantics of the HTTP response headernamed by this attribute is known, then the contents can be processedbased on a well defined syntactic mapping, whether or not the DTDincludes anything about it. HTTP header names are not case sensitive.If absent, the NAME attribute should be used to identify thismeta-information and it should not be used within an HTPP responseheader.
Examples:
If the document contains:
<META HTTP-EQUIV=Expires CONTENT="Tue, 04 Dec 1993 21:29:02 GMT"><META HTTP-EQUIV="Keywords" CONTENT="Nanotechnology, Biochemistry"><META HTTP-EQUIV="Reply-to" CONTENT="dsr@w3.org (Dave Raggett)">The server will include the following response headers:
Expires: Tue, 04 Dec 1993 21:29:02 GMTKeywords: Nanotechnology, BiochemistryReply-to: dsr@w3.org (Dave Raggett)
When the HTTP-EQUIV attribute is absent, the server should notgenerate an HTTP response header for this meta-information, e.g.
<META NAME="IndexType" CONTENT="Service">
Do not use the META element to define information that should beassociated with an existing HTML element.
Example of an inappropriate use of the META element:
<META NAME="Title" CONTENT="The Etymology of Dunsel">
Do not name an HTTP-EQUIV attribute the same as a response headerthat should typically only be generated by the HTTP server. Someinappropriate names are "Server", "Date", and "Last-Modified". Whethera name is inappropriate depends on the particular serverimplementation. It is recommended that servers ignore any META elementsthat specify HTTP equivalents (case insensitively) to their ownreserved response headers.
NEXTID
The NEXTID is a parameter read and generated by text editingsoftware to generate unique identifiers. This tag takes a singleattribute which is the the next document-wide alpha-numeric identifierto be allocated of the form z123.
When modifying a document, existing anchor identifiers should not bereused, as these identifiers may be referenced by other documents.Human writers of HTML usually use mnemonic alphabetical identifiers.
Example:
<NEXTID N=Z27>
HTML user agents may ignore the NEXTID element. Support for NEXTIDdoes not impact HTML user agents in any way.
I want to get rid of NEXTID, or at least deprecate it!
RANGE
The RANGE element is used to mark a range of the document, for examplefor highlighting regions of the document matching some search criteria,or which are the subject of an annotation etc.
<RANGE CLASS=Search FROM=spot01 UNTIL=spot02>The FROM and UNTIL attributes specify positions in the document usingSGML identifiers. Most elements in the document body can define suchidentifiers using ID attributes. The SPOT element is useful in thisregard, as it allows search software etc. to insert IDs at random places:
<SPOT ID=spot01> ... <SPOT ID=spot02>
The RANGE element supports the following attributes:
- ID
- An SGML identifer used to name the range element.
- CLASS
- A character string used to subclass the range element.
- FROM
- References an SGML identifier for an element in thedocument body. It identifies the start of the marked range.
- UNTIL
- References an SGML identifier for an element in thedocument body. It identifies the end of the marked range.
STYLE
The STYLE element provides a means for including rendering informationusing a specified style notation. Information in the STYLE elementoverrides client defaults and that of linked style sheets. It allowsauthors to specify overrides, while for the most part using a genericstyle sheet, and as such improves the effectiveness of caching schemesfor linked style sheets. There is one attribute - NOTATATION - whichspecifies an entity identifying an SGML notation in the HTML 3.0 DTD,for example:
<style notation=dsssl-lite> some dsssl-lite stuff ... </style>
Stylistic rules will in general match tag names and attribute valuesfor elements in the document body. Context sensitive rules may be usedfor such purposes as rendering drop down capitals for the initialletter in the first paragraph following a header.
TITLE
Every HTML document must contain a TITLE element. The title shouldidentify the contents of the document in a global context, and may beused in a history lists and as a label for the window displaying thedocument. Unlike headings, titles are not normally displayed in thetext of a document itself.
The TITLE element must occur within the head of the document, andmay not contain anchors, paragraph tags, or highlighting. There mayonly be one TITLE in any document.
The length of titles is unlimited, however, long titles may betruncated in some applications. To minimize this possibility, keeptitles to fewer than 64 characters. Also keep in mind that a shorttitle, such as Introduction, may be meaningless out of context. Anexample of a meaningful title might be:
<Title>Recent Advances in Nanotechnology</Title>