The mechanism by which map processors discover maps to be anchored is processor specific.
The <anchor> element is typically used to allow integration of run-time components. For build-time integration, you can use a <topicref> element to reference another map, or use the @conref or @conkeyref attribute on an element inside the map.
See appendix for information about this element in OASIS document type shells.
In this example, the
map1.ditamap contains an
<anchor> element with an
@id attribute set to "a1".
DITA map that contains an anchor
<map> <title>MyComponent tasks</title> <topicref navtitle="Start here" href="start.dita" toc="yes"> <navref mapref="othermap2.ditamap"/> <navref mapref="othermap3.ditamap"/> <anchor id="a1"/> </topicref> </map>
The @id on an <anchor> element can be referenced by the @anchorref attribute on another map's <map> element. For example, the map to be integrated at that spot could be defined as follows.
DITA map that references an anchor
<map anchorref="map1.ditamap#a1"> <title>This map is pulled into the MyComponent task map</title> <!-- ... --> </map>
- @id (REQUIRED)
- Provides an integration point that another map can reference in order to insert its navigation into the current navigation tree. The @anchorref attribute on a map can be used to reference this attribute. See ID attribute for more details.