<!ELEMENT BASE - O EMPTY -- document base URI -->
<!ATTLIST BASE
href %URI; #REQUIRED -- URI that acts as base URI --
>
Start tag: required, End tag: forbidden
Attribute definitions
- href = uri [CT]
- This attribute specifies an absolute URI that acts as the base URI for resolving relative URIs.
Attributes defined elsewhere
In HTML, links and references to external images, applets, form-processing programs, style sheets, etc. are always specified by a URI. Relative URIs are resolved according to a base URI, which may come from a variety of sources. The BASE element allows authors to specify a document's base URI explicitly.
When present, the BASE element must appear in the HEAD section of an HTML document, before any element that refers to an external source. The path information specified by the BASE element only affects URIs in the document where the element appears.
For example, given the following BASE declaration and A declaration: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<HTML>
<HEAD>
<TITLE>Our Products</TITLE>
<BASE href="http://www.aviary.com/products/intro.html">
</HEAD>
<BODY>
<P>Have you seen our <A href="../cages/birds.gif">Bird Cages</A>?
</BODY>
</HTML>
the relative URI "../cages/birds.gif" would resolve to: http://www.aviary.com/cages/birds.gif |