$Revision: 1.3 $

$Date: 2002/06/12 11:18:19 $

olink — A link that addresses its target indirectly, through an entity


Mixed Content Model

olink ::=


Common attributes




localinfo CDATA None
type CDATA None
linkmode IDREF None
targetptr CDATA None
targetdoc CDATA None
targetdocent ENTITY None


Unlike Link and ULink, the semantics of OLink are application-specific. OLink provides a mechanism for establishing links across documents, where ID/IDREF linking is not possible and ULink is inappropriate.

In general terms, the strategy employed by OLink is to point to the target document via an external general entity, and point into that document in some application-specific way.

Processing expectations

Formatted inline.

OLink points to its target primarily with the TargetDocEnt attribute. TargetDocEnt must be the name of an entity (previously declared in the DTD or in the document subset).

Because TargetDocEnt is an entity attribute, the entity used as its value must be declared with a notation. Because the target is usually another SGML or XML document, the notation SGML is most often used:

<!ENTITY myotherdoc SYSTEM "myotherdoc.sgm" NDATA SGML>

The semantics of the link are controlled by three other attributes: LinkMode, LocalInfo, and Type. The LinkMode attribute points to a ModeSpec. The content of ModeSpec describes the semantic of the link in an entirely application-specific way.

The values of LocalInfo and Type may also influence the application. For example, if the ModeSpec describes some sort of query, LocalInfo might hold the query text (allowing multiple OLinks to use the same ModeSpec to achieve different queries with the same query engine).

Linking elements must not be nested within other linking elements (including themselves). Because DocBook is harmonizing towards XML, this restriction cannot easily be enforced by the DTD. The processing of nested linking elements is undefined.

Future Changes

The InterfaceDefinition element will be discarded in DocBook V4.0. It will no longer be available in the content model of this element.


These elements contain olink: abbrev, ackno, acronym, action, application, artpagenums, attribution, authorinitials, bibliocoverage, biblioid, bibliomisc, bibliorelation, bibliosource, bridgehead, citation, citebiblioid, citetitle, city, classsynopsisinfo, collabname, command, computeroutput, confdates, confnum, confsponsor, conftitle, contractnum, contractsponsor, contrib, corpauthor, corpname, country, database, date, edition, email, emphasis, entry, fax, figure, filename, firstname, firstterm, foreignphrase, funcparams, funcsynopsisinfo, function, glosssee, glossseealso, glossterm, hardware, holder, honorific, indexdiv, informalfigure, interfacename, invpartnumber, isbn, issn, issuenum, jobtitle, keycap, label, lineage, lineannotation, link, literal, literallayout, lotentry, manvolnum, member, modespec, msgaud, olink, option, optional, orgdiv, orgname, otheraddr, othername, pagenums, para, parameter, phone, phrase, pob, postcode, primary, primaryie, productname, productnumber, programlisting, property, pubdate, publishername, pubsnumber, quote, refentry, refentrytitle, refmiscinfo, refnamediv, refpurpose, releaseinfo, remark, replaceable, revnumber, revremark, screen, screeninfo, secondary, secondaryie, see, seealso, seealsoie, seeie, seg, segtitle, seriesvolnums, shortaffil, simpara, state, street, subscript, subtitle, superscript, surname, synopsis, systemitem, term, tertiary, tertiaryie, title, titleabbrev, tocback, tocentry, tocfront, trademark, ulink, userinput, volumenum, wordasword, year.



LinkMode points to the ModeSpec which provides additional application-specific information for resolving this OLink.


LocalInfo hold additional information that may be used with the ModeSpec (pointed to by LinkMode) by the application when resolving this OLink.


TargetDocEnt specifies the name of an entity that is to be used as part of the OLink. Exactly how the link is resolved is application dependent and may be influenced by the MoreInfo and LocalInfo attributes.


Type is available for application-specific customization of the linking behavior.

See Also

anchor, link, ulink, xref.


In this example, we see how an OLink might be used for searching. Here the ModeSpec describes the search query (in a fictitious and entirely concocted syntax): “look in the titles of sections and return links using the title as the text of the link”. When the user selects the link, the application is expected to perform the query and then might display the list of titles as a pop-up window in the user interface.

<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
                  "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd" [
<!ENTITY refbook SYSTEM "refbook.sgm" CDATA SGML>
  <modespec id="s1query">query in sect*, title return link text title</modespec>

Blah, blah, blah.

<sect1><title>See Also</title>
For more information <olink targetdocent="refbook" linkmode="s1query"
localinfo="print or printing">about printing</olink>, consult
the <ulink url="refbook.sgm">reference manual</ulink>.