Body elements
The body elements support the most common types of content
authoring for topics: paragraphs, lists, phrases, figures, and other
common types of exhibits in a document.
- altThe alt element provides alternate text for an image. It is equivalent to the alt attribute on the image element; since the attribute is deprecated, use the alt element instead. As an element, alt provides direct text entry within an XML editor and is more easily accessed than an attribute for translation.
- citeThe <cite> element is used when you need a bibliographic citation that refers to a book or article. It specifically identifies the title of the resource.
- ddThe definition description (<dd>) element contains the description of a term in a definition list entry.
- descThe <desc> element contains the description of the current element. In elements that also allow a title, such as table and fig, this is used to provide more information than is appropriate for the title. In the xref and link elements it contains a description of the target; processors may (but need not) choose to display this as hover help for a link. In the object element, desc provides alternate content to use when the context does not permit displaying the object.
- ddhdThe <ddhd> element contains an optional heading or title for a column of descriptions or definitions in a definition list.
- dlA definition list (<dl>) is a list of terms and corresponding definitions. The term (<dt>) is usually flush left. The description or definition (<dd>) is usually either indented and on the next line, or on the same line to the right of the term. However, actual rendering is up to the rendering engine.
- dlentryIn a definition list, each list item is defined by the definition list entry (<dlentry>) element. The definition list entry element includes a term <dt> and one or more definitions or descriptions <dd> of that term.
- dlheadThe <dlhead> element contains optional headings for the term and description columns in a definition list. The definition list heading may contain a heading <dthd> for the column of terms and a heading <ddhd> for the column of descriptions.
- dtThe definition term <dt> element contains a term in a definition list entry.
- draft-commentThe <draft-comment> element is designed to facilitate review and discussion of topic contents within the marked-up content. Use the <draft-comment> element to ask a question or to make a comment that you want others to review. To indicate the source of the draft comment or the status of the comment, use the author, time or disposition attributes.
- dthdThe definition term heading (<dthd>) element is contained in a definition list head (<dlhead>) and provides an optional heading for the column of terms in a description list.
- exampleThe <example> element is a section with the specific role of containing examples that illustrate or support the current topic. The <example> element has the same content model as <section>.
- figThe figure (<fig>) element is a display context (sometimes called an
exhibit
) with an optional title for a wide variety of content. Most commonly, the figure element contains an image element (a graphic or artwork), but it can contain several kinds of text objects as well. A title is placed inside the figure element to provide a caption that describes the content. - figgroupThe <figgroup> element is used primarily for specialization, in order to create segments within a figure. The element may nest itself, which allows it to create complex specialized structures (such as the nestable groups of syntax within a syntax diagram). Figure groups can be used to contain multiple cross-references, footnotes or keywords, but not multipart images. Multipart images in DITA should be represented by a suitable media type displayed by the <object> element.
- fnUse footnote (<fn>) to annotate text with notes that are inappropriate for inline inclusion or to indicate the source for facts or other material used in the text.
- imageInclude artwork or images in a DITA topic by using the <image> element. The <image> element has optional attributes that indicate whether the placement of the included graphic or artwork should be inline (like a button or icon) or on a separate line for a larger image. There are also optional attributes that indicate the size to which the included graphic or artwork should be scaled. An image element must specify an href attribute, a keyref attribute, or both. When both keyref and href are specified, the href is used as a fallback when the key reference cannot be resolved. The image addressed by the keyref or href is brought into the main flow of the content as rendered. To make the intent of the image more accessible for users using screen readers or text-only readers, authors should include a description of the image's content in the alt element.
- keywordThe <keyword> element identifies a keyword or token, such as a single value from an enumerated list, the name of a command or parameter, product name, or a lookup key for a message.
- liA list item (<li>) is a single item in an ordered (<ol>) or unordered (<ul>) list. When a DITA topic is rendered, numbers and alpha characters are usually displayed with list items in ordered lists, while bullets and dashes are usually displayed with list items in unordered lists.
- linesThe <lines> element may be used to represent dialogs or text fragments where line breaks are significant. The <lines> element is similar to <pre> in that hard line breaks are preserved, but the font style is not set to monospace, and extra spaces inside the lines are not preserved.
- longdescrefThe <longdescref> element supports a reference to a text description of the graphic or object. This element replaces the deprecated longdescref attribute on image and object elements.
- longquoterefThe <longquoteref> element provides a reference to the source of a long quote. The long quote (<lq>) element itself allows an href attribute to specify the source of a quote, but it does not allow other standard linking attributes such as keyref, scope, and format. The <longquoteref> element should be used for references that make use of these attributes.
- lqThe long quote (<lq>) element indicates content quoted from another source. Use the quote element <q> for short, inline quotations, and long quote <lq> for quotations that are too long for inline use, following normal guidelines for quoting other sources. You can store a URL to the source of the quotation in the href attribute; the href value may point to a DITA topic. For more complex references to the source of a quote, you may use the <longquoteref> element, which was added in DITA 1.2.
- objectDITA's <object> element corresponds to the HTML <object> element, and its attributes' semantics derive from their HTML definitions. For example, the type attribute differs from the type attribute on many other DITA elements.
- noteA <note> element contains information, differentiated from the main text, which expands on or calls attention to a particular point.
- olAn ordered list (<ol>) is a list of items sorted by sequence or order of importance.
- pA paragraph element (<p>) is a block of text containing a single main idea.
- paramThe parameter (<param>) element specifies a set of values that may be required by an <object> at runtime. Any number of <param> elements may appear in the content of an object in any order, but must be placed at the start of the content of the enclosing object. This element is comparable to the XHMTL <param> element, and its attributes' semantics derive from their HTML definitions. For example, the type attribute differs from the type attribute on many other DITA elements.
- phThe phrase (<ph>) element is used to organize content for reuse or conditional processing (for example, when part of a paragraph applies to a particular audience). It can be used by specializations of DITA to create semantic markup for content at the phrase level, which then allows (but does not require) specific processing or formatting.
- preThe preformatted element (<pre>) preserves line breaks and spaces entered manually by the author in the content of the element, and also presents the content in a monospaced type font (depending on your output formatting processor). Do not use <pre> when a more semantically specific element is appropriate, such as <codeblock>.
- qA quotation element (<q>) indicates content quoted from another source. This element is used for short quotes which are displayed inline. Use the long quote element (<lq>) for quotations that should be set off from the surrounding text.
- sectionThe <section> element represents an organizational division in a topic. Sections are used to organize subsets of information that are directly related to the topic. For example, the titles Reference Syntax, Example and Properties might represent section-level discourse within a topic about a command-line process—the content in each section relates uniquely to the subject of that topic. Multiple sections within a single topic do not represent a hierarchy, but rather peer divisions of that topic. Sections cannot be nested. A section may have an optional title.
- sectiondivThe <sectiondiv> element allows logical grouping of content within a section. There is no additional meaning associated with the sectiondiv element, aside from its function as a container for other content. The sectiondiv element does not contain a title; the lowest level of titled content within a topic is the section itself. If additional hierarchy is required, nested topics should be used in place of the section.
- slThe <sl> element contains a simple list of items of short, phrase-like content, such as a list of materials in a kit or package.
- sliThe <sli> element is an item in a simple list (<sl>). Simple list items have phrase or text content, adequate for describing package contents, for example. When a DITA topic is formatted for output, the items of a simple list should be placed each on its own line, with no other prefix such as a number (as in an ordered list) or bullet (as in an unordered list).
- termThe <term> element identifies words that may have or require extended definitions or explanations.
- textThe text element associates no semantics with its content. It exists to serve as a container for text where a container is needed (e.g., for conref, or for restricted content models in specializations). Unlike ph, text cannot contain images. Unlike keyword, text does not imply keyword-like semantics. The text element contains only text data, or nested text elements. All universal attributes are available on text.
- tmThe trademark (<tm>) element in DITA is used to markup and identify a term or phrase that is trademarked. Trademarks include registered trademarks, service marks, slogans and logos.
- ulIn an unordered list (<ul>), the order of the list items is not significant. List items are typically styled on output with a "bullet" character, depending on nesting level.
- xrefUse the cross-reference (<xref>) element to link to a different location within the current topic, or a different topic within the same help system, or to external sources, such as Web pages, or to a location in another topic. The target of the cross-reference is specified using the href or keyref attributes.
Previous topic: Basic topic elements
Next topic: Table elements
Parent topic: Topic elements