Hypertext Links
[Top] [Up] [Next] [Previous]

5.2 - Hypertext Links


HTML+ allows authors to embed hypertext links into the document text. In a browser this might look to the reader like:

Clicking on a link will normally cause the browser to retrieve the linked document and display it in place of the current one. This example is represented by the following piece of HTML+

Links are defined with the <a href="#z1">A tag</a>. HTML+ supports a
number of <a href="links.html">different link types.
The first link is to an anchor named "z1" in the current document (using an ID attribute on some element). The second is to a file named "links.html" in the same directory as the current document. The link caption is the text between the start and end tags. The HREF attribute defines the link destination using the URL or URN notations. This may be abbreviated in certain circumstances using relative URLs. The link should be rendered in a clearly distinguishable way, e.g. as a raised button, or with underlined text in a particular color or emphasis. For displays without pointing devices, it is suggested that the link is indicated with a reference number in square brackets after the caption, which the reader enters to follow the link. Note that it is illegal for anchors to include headers, paragraphs, lists etc. The anchor text is restricted to normal text with emphasis and inline images.

The A element has several optional attributes:

ID
This can be used to define a unique identifier for the text contained by the A element. Another document can then make a reference to this by putting the identifier after the URL for this document, separated by a hash sign. The ID attribute replaces the NAME attribute in HTML.
HREF
This specifies a URL or URN of a linked document which will be retrieved when the user clicks on the anchor's label. HREF=#id can be used for links to other parts of the same document.
REL
The relationship the linked document has to this one. REL=Subdocument is used to break long documents into smaller ones. This importance of this particular attribute value is explained in Section 14.
REV
The reverse relationship type, and the inverse of REL.
EFFECT
This determines how the browser displays the linked document when following the link. EFFECT=Replace causes the browser to replace the current document with the linked one; EFFECT=NEW results in the linked document being shown in a new window (if practical); and EFFECT=OVERLAY causes the linked document to be shown in a pop-up window, as used by the Microsoft Windows Help system.
PRINT
This attribute makes it easy for users to print off the current document and relevant parts. PRINT=REFERENCE (the default) treats the link as a reference, i.e. the URL is given as a footnote; PRINT=FOOTNOTE prints the linked document as a footnote; PRINT=SIDEBAR prints the linked document as a sidebar; and PRINT=SECTION prints the linked document as a follow on section. Use PRINT=SILENT when you don't want the link referenced or printed out*1.
TITLE
Defines the title to use when the linked document is otherwise untitled.
TYPE
The MIME content type of the linked document - for use in providing presentation cues only, as it could easily become out of date.
SIZE
The size in bytes for the linked document. This should only be used as a guide to progress in retrieving documents, as it is likely to get out of step with changes to the target document.
METHODS
This is a comma separated list of HTTP methods supported by the linked object. The browser might choose a different way of rendering the link for say searchable objects.
SHAPE
This is used to define shaped buttons on top of images or figures, and is explained later on. You can also use the LINK element at the start of the document to define document-wide relationships with other documents, e.g. a link to a table of contents. This is described later on.


HTML+ Discussion Document - November 8, 1993

[Top] [Up] [Next] [Previous]