Name
<xsl:id>
Synopsis
<xsl:id attribute="
value
"
[element="
element
"
]/>
Description
Identifies a specific attribute that appears in an XML
element as an XML ID attribute. This is useful in the event that
an XML document without a corresponding DTD needs to be
formatted. If element
is used, only attributes localized
to that element are marked as ID attributes. If element
is omitted, the XML processor assumes that all element
attributes matching the value
specified, no matter what the
element, should be treated as ID attributes:
<xsl:id attribute="id"/> <xsl:id attribute="marker" element="Body"/>
You are allowed to use multiple <xsl:id>
elements. However,
remember that the same ID cannot be assigned to more than one
XML element at a time. If this instruction identifies several
XML attributes as ID attributes such that any of those
attributes have identical values, the XML processor could generate
an error.
This element may change in the future.
Get Webmaster in a Nutshell, Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.