The <data> element represents a property within a DITA topic or map. While the <data> element can be used directly to capture properties, it is particularly useful as a basis for specialization. Default processing treats the property values as an unknown kind of metadata, but custom processing can match the name attribute or specialized element to format properties as sidebars or other adornments or to harvest properties for automated processing.
The subject of the property is ordinarily the container of the <data> element. In the content model for the <prolog> and <metadata> elements, the property applies to the topic as a whole. In the <topicmeta> element, the property applies to the referenced topic. You can use the <data-about> element to identify the subject of the property with an explicit reference.
The name attribute names the property for processes. You can use a <title> subelement to provide a label for the property. You can use the datatype attribute to identify the type for the value. The value of the property can be any of the following:
The structure identifies the library and version demonstrated by a code sample:
<codeblock><data name="exampleOf"> <data name="library" href="ajaxLibrary.js"/> <data name="version" value="2006-6-19"/> </data> ... </codeblock>
Doctype | Content model |
---|---|
ditabase, topic, task, reference, concept | ( text data or keyword or option or parmname or apiname or cmdname or msgnum or varname or wintitle or term or data or data-about or foreign or unknown or image or object or ph or codeph or synph or filepath or msgph or userinput or systemoutput or b or u or i or tt or sup or sub or uicontrol or menucascade or title) (any number) |
map, bookmap | ( text data or keyword or term or data or data-about or foreign or unknown or image or object or ph or title) (any number) |
- topic/data
Name | Description | Data Type | Default Value | Required? |
---|---|---|---|---|
name | Defines a unique name for the object. | CDATA | #IMPLIED | No |
datatype | Describes the type of data contained in the value attribute or within the data element. A typical use of datatype will be the identifying URI for an XML Schema datatype. | CDATA | #IMPLIED | No |
value | Specifies the value of a run-time parameter specified by the name attribute. | CDATA | #IMPLIED | No |
href | A hyperlink to an external Web page (URL) or other non-DITA resource,
or to another DITA topic in the same file or in another file. The format attribute
identifies the format of the target. Non-DITA targets use standard URL syntax.
DITA topics are targetted as follows:Target elsewhere in the same file: href="#topicid" First topic in different file: href="filename.dita" Specific topic in different file: href="filename.dita#topicid" If the URL contains an ampersand character, the ampersand symbol (&) should be used to indicate that character |
CDATA | #IMPLIED | No |
format | The format attribute identifies the format of the resource being cross referenced. See The format attribute for details on supported values. | CDATA | #IMPLIED | No |
type | Describes the target of a cross-reference. See The type attribute for detailed information on supported values and processing implications. | CDATA | #IMPLIED (Processed as if the target were of type "topic", or inherited from an ancestor) | No |
scope | The scope attribute identifies the closeness of the relationship
between the current document and the target resource.
|
(local | peer | external | -dita-use-conref-target) | #IMPLIED | No |
%univ-atts; (%select-atts;, %id-atts;, %localization-atts;) | A set of related attributes, described at %univ-atts; | parameter entity | PE not applicable | Not applicable |
%global-atts; (xtrf, xtrc) | A set of related attributes, described at %global-atts; | parameter entity | PE not applicable | Not applicable |
class, outputclass | Common attributes described in Other common DITA attributes. |
Return to main page.
OASIS DITA Language Specification v1.1 -- Committee Draft 13 February 2007
Copyright © OASIS Open 2005, 2007. All Rights Reserved.