|
To access the contents, click the chapter and section titles.
HTML 4.0 Sourcebook
BASE is an empty element and is optional. BASE has a single mandatory attribute, HREF, which is assigned the base URL of the document. The base URL references where the document was originally located. Consequently, a document can have at most one BASE element. BASE is useful for documents moved away from their original URLafter moving the document, partial URLs that referenced neighboring documents are no longer valid. However, if the original URL address is specified in a BASE element, relative URLs from this document are evaluated relative to this base URL and are correctly referenced at the original location. If the BASE element is absent, the browser determines partial URLs relative to the URL used to access the document.
The following is an example of the appropriate use of BASE. If a document was originally found at the URL: http://somewhere.org/Dir/Subdir/file.html the appropriate BASE element to include in this document is: <HEAD> <TITLE> some sort of title.... </TITLE> <BASE HREF=http://somewhere.org/Dir/Subdir/file.html> </HEAD> BASE Support for Netscape Frames Browsers that support the frame elements support targeted linksthis lets a document author direct the data returned, upon selecting a hypertext link, to a particular named browser window or named pane within a windowall browsers can produce multiple copies of themselves, while frame-capable browsers can create multiple window panes within a single browser window. Named windows are produced by using a TARGET attribute to the A (anchor) element or by using the FRAMESET element, as discussed in Chapter 7. Browsers that support frames also support a TARGET attribute with the BASE element. Analogous to the value of HREF, TARGET defines the default name of the target window for all hypertext links within the document. For example, the element <BASE TARGET=window3> means that all accessed hypertext links will be displayed in (sent to) the window named window3 . If a pane by this name does not already exist, then a new browser window will be created, and will be assigned this name. A BASE-specified target is overridden by an explicit TARGET within an anchor, such as: <A HREF=/path/file.html TARGET=window2>anchor text</A> The document returned upon accessing this anchor will be directed to the window named window2, overriding any target implied by the BASE element TARGET value. The default target is always the window or frame containing the document currently being displayed. ISINDEX Element: Searchable Document
ISINDEX is an optional, empty element. Because there are many older documents that have ISINDEX in the BODY, HTML allows this placement; ideally, ISINDEX should be inside the HEAD. This element informs the browser that the document can be examined using a keyword search and that the browser should query the user for a search or query string. The attribute PROMPT, which takes as its value an arbitrary author-specified string, specifies the prompt that should be presented for this query; for example: <ISINDEX PROMPT=Please enter your favorite ice cream flavor:> ISINDEX does not mean a search of the text being read. Documents containing ISINDEX elements are usually sent to the client from server-side gateway programs designed for database searches. You can think of such a document as a front end to a gateway program and the document you search as the database represented by the document you see. By default, ISINDEX-accepted data are returned to the same URL that was used to retrieve the document containing the ISINDEX element. Several browsers support an ACTION attribute, which takes as its value a URL to which the query should instead be directed. This is supported by both Navigator and Internet Explorer.
The encoding mechanism by which ISINDEX query data are appended to a URL is discussed in the http URL section of Chapter 8 and also in Chapter 10. LINK Element: Relationship to Other Documents
LINK describes a relationship between a document and other documents or objects. For example, LINK can indicate a related index, a glossary, or perhaps different versions of the same document. Alternatively, LINK can point out likely next or previous documents. This information could be used by a browser, among other things, to predict and preload documents it is likely to need, or to configure customized navigational buttons or menus. A document may have any number of LINK elements to represent these various relationships to other documents. LINK is an empty element and is optional. The HREF attribute (a URL that points to the linked resource) is mandatory, as is at least one of REL or REV: REL or REV take text string values that define the nature of the relationship between the linked resources. All other attributes are optional. Indeed, most other attributes are not understood by current browsers.
|
Products | Contact Us | About Us | Privacy | Ad Info | Home
Use of this site is subject to certain Terms & Conditions, Copyright © 1996-2000 EarthWeb Inc. All rights reserved. Reproduction whole or in part in any form or medium without express written permission of EarthWeb is prohibited. Read EarthWeb's privacy statement. |