<dita>

The <dita> element is the root element for the ditabase document type.

Usage information

The ditabase document type is a container topic that can manage any sequence of any type of topic. It can be used to hold elements designed for reuse, and it is also useful as an intermediate output for conversion operations.

The <dita> element cannot be specialized. Topic nesting rules can be configured in the document-type shell.

Attributes

The following attributes are available on this element: @xmlns:ditaarch, @DITAArchVersion, and localization attributes.

@dir

Identifies or overrides the text directionality. The following values are valid:

lro
Indicates an override of the Unicode Bidirectional Algorithm, forcing the element into left-to-right mode.
ltr
Indicates left-to-right.
rlo
Indicates an override of the Unicode Bidirectional Algorithm, forcing the element into right-to-left mode.
rtl
Indicates right-to-left.
-dita-use-conref-target
See Using the -dita-use-conref-target value for more information.

See The dir attribute for more information.

@DITAArchVersion (architectural attributes)
Specifies the version of the DITA architecture that is in use. This attribute is in the namespace http://dita.​oasis-open.​org/​architecture/​2005/. This attribute is specified in the topic and map modules, and it uses a default value of the current version of DITA. The current default is 2.0.
@translate
Specifies whether the content of the element should be translated. The following values are valid: yes, no, and -dita-use-conref-target.

See Element-by-element recommendations for translators for suggested processing defaults for each element.

@xml:lang
Specifies the language and optional locale of the content that is contained in an element. Valid values are language tokens or the null string. The @xml:lang attribute and its values are described in the Extensible Markup Language 1.0 specification, fifth edition.
@xmlns:ditaarch (architectural attributes)
Declares the default DITA namespace. This namespace is declared as such in the RNG modules for <topic> and <map>, but it is specified as an attribute in the equivalent DTD-based modules. The value is fixed to http://dita.​oasis-open.​org/​architecture/​2005/.

Example

This section is non-normative.

The following code sample shows a ditabase document that contains multiple topics. The <concept>, <reference>, and <task> elements are all specializations of <topic>.

<dita>
  <concept id="batintro">
    <title>Intro to bats</title>
    <conbody>
      <!-- ... -->
    </conbody>
  </concept>
  <task id="batfeeding">
    <title>Feeding a bat</title>
    <taskbody>
      <!-- ... -->
    </taskbody>
  </task>
  <reference id="batparts">
    <title>Parts of bats</title>
    <refbody>
      <!-- ... -->
    </refbody>
  </reference>
      <!-- ... -->
</dita>