HTML 3.2 and Netscape 3.0: The HEAD Element and Related Elements | WebReference

HTML 3.2 and Netscape 3.0: The HEAD Element and Related Elements


The HEAD Element

HTML 3.2 and Netscape 3.0

The <HEAD> element in HTML 3.2 [Ra 95a] works identically to NHTML. Information in the <HEAD> element corresponds to the top part of a memo or e-mail message. It describes properties of the document such as the title, document toolbar, scripts, and meta information. The HEAD start and end tags are optional.

HEAD Elements

The BASE element defines an absolute URL that resolves relative URLs within the document. It is also useful if your document is downloaded or read out of context. Ex:

<BASE href="">
<IMG SRC="art/logo.jpg">

The image is deferenced to

Without the BASE element relative URLs are resolved to the document's URL.

Used for simple keyword searches, and works with the PROMPT attribute. The ISINDEX element actually calls itself, so files with ISINDEX tags are usually scripts themselves. Ex:

<ISINDEX PROMPT="Enter search string: ">

The LINK element defines relationships between the document and other documents. It can be used to create tool bars, link to a style sheet (rev=stylesheet), a script (rev=script), or a printable version (like a pdf) of the document (rev=print) and embed authorship details. LINK should always be accompanied by an HREF to indicate the resource it refers to, the other attributes are optional. The LINK attributes are (from the HTML 3.2 DTD):
        id       SGML ID attribute
        href     URL for linked resource
        rel      forward link types
        rev      reverse link types
        title    advisory title string

<LINK HREF="summary.html" TITLE="Summary" REV="Home">
<LINK HREF="chap4.html" TITLE="Color Palettes" REL="chapter">
<LINK HREF="" TITLE="Andy King" REV="author">

The META element allows for including information about the document not defined by other elements. It is used to supply generic meta information using name/value pairs. The CONTENT attribute is required, with either the HTTP-EQUIV or NAME attribute to identify the type of action or data identifier to be associated with it.

Ex: (first example used for search engines, second shows currency of page)

<META Name="description" Content="Home page for,
a Web site about creating Web sites. Learn the art of Web site creation.">

<META Name="keywords" Content=", HTML,
frames, webmaster reference library, HTML reference, HTML authoring,...>

<META NAME="Last-Modified" CONTENT="8-26-96">

NHTML Ex: (after 10 seconds this page will refresh (move) to the "next" page)

<META HTTP-EQUIV="Refresh" CONTENT="10; URL=next.html">
<P>...Mr. Phelps, this page will self destruct in 10 seconds...</P>

The SCRIPT element is included as a placeholder for future use with script languages. It is already in use in the newest versions of Netscape and Explorer. Common practice is to surround the script proper with comments so older browsers don't see the script. Ex:


<!--// hide from other browsers

/* JavaScript Livepopup Navigator
   Generic arrays and select menus
   by Andy King (

function createArray() {
this.length = createArray.arguments.length
for (var i = 0; i this[i+1] = createArray.arguments[i]

var title = new createArray("Select a page...",
"Developer's Corner",
"Feature Articles",
// -->

NHTML The SRC attribute to the SCRIPT tag allows hiding of scripts. Ex:

<SCRIPT LANGUAGE="JavaScript" SRC=mySource.js>

The STYLE element is included as a placeholder for future use with style sheets.

The <TITLE> element is not part of the body text, it is displayed in the window title. The <TITLE> element is required and should contain only text and no markup. Your title should be descriptive but short, less than 64 characters. The title should stand on its own when accessed directly. Ex:

<HEAD><TITLE>&nbsp;S&nbsp;Sc...</TITLE> or
<TITLE>Page 5 of report &#174; or <H1>BIG TEXT?</H1></TITLE>

<HEAD><TITLE>Include only descriptive text here, less than 64 characters</TITLE>


Comments are welcome


Revised: Aug. 25, 1996