Name
<xsl:variable>
Synopsis
<xsl:variable name=”name
" [select=”expression
“]> ... </xsl:variable>
The top-level xsl:variable
element binds
a name to a value of any type (string, number, node set, etc.). The
value can then be dereferenced elsewhere in the stylesheet using
the form $
name
in
attribute value templates. Once a variable name has been assigned
a value, it cannot change. The select
attribute
is an optional expression that sets the value of the variable. If
xsl:variable
has a select
attribute, then it must be an empty element.
Get XML Pocket Reference, 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.