The <coderef> element references an external file that contains literal code. When evaluated, the <coderef> element should cause the target code to be displayed inline. If the target contains non-XML characters such as '<' or '&', those will need to be handled in a way that they may be displayed correctly by the final rendering engine. This element is part of the DITA programming domain, a special set of DITA elements designed to document programming tasks, concepts, and reference information.
topic (technical content), map (technical content), concept, ditabase, glossary, glossentry, glossgroup, reference, task, bookmap |
topic (technical content), map (technical content), concept, ditabase, glossary, glossentry, glossgroup, reference, task (strict), task (general), bookmap |
<example> <title>Processing DITA</title> <p>This code is an example of how to process DITA.</p> <codeblock><coderef href="process-dita.xsl"/></codeblock> </example>
Provides a reference to a resource. See 3.4.2.1 The href attribute for detailed information on supported values and processing implications. |
||||
Describes the target of a reference. See 3.4.2.8 The type attribute for detailed information on supported values and processing implications. |
||||
The format attribute identifies the format of the resource being referenced. See 3.4.2.9 The format attribute for details on supported values. |
||||
The scope attribute identifies the closeness of the relationship between the current document and the target resource. See 3.4.2.10 The scope attribute for more information on values. |
||||
univ-atts attribute group (includes select-atts, id-atts, and localization-atts groups) |
A set of related attributes, described in 3.4.1.3 univ-atts attribute group |
|||
A set of related attributes, described in 3.4.1.2 global-atts attribute group |
||||
Class and outputclass are described in 3.4.1.9 Other common DITA attributes |