xsl:namespace-alias
A top-level element used to control the mapping between a namespace URI used in the stylesheet and the corresponding namespace URI used in the result document.
Category: declaration
Content: none
Permitted parent elements:
xsl:stylesheet
; xsl:transform
Attributes
|
|
|
|
|
Details
Normally when a literal result element is
encountered in a template, the namespace used for the element name and attribute
names in the result document is the same as the namespace used in the
stylesheet. If a different namespace is wanted (e.g. because the result document
is a stylesheet using the XSLT namespace), then xsl:namespace-alias
can be used to define the mapping.
Examples
The following example allows the prefix outxsl
to be used for
output elements that are to be associated with the XSLT namespace. It
assumes that both namespaces xsl
and outxsl
have
been declared and are in scope.