July 2001
Intermediate to advanced
592 pages
11h 16m
English
<xsl:variable>
<xsl:param>
<xsl:with-param>
XSLT provides the functionality to create special values that can be declared and used by expressions in other elements in the stylesheet. These values are attached, or bound, to named objects called variables. A variable in XSLT can be either global (available throughout the stylesheet) or local (available only to the element where it is declared), and it must be declared before it can be used.
In this chapter, we will discuss the two ways to declare variables in XSLT, using either <xsl:variable> or <xsl:param>, and the process of calling, or referencing, variable values. We will also discuss <xsl:with-param>, which allows a template to override the value of a variable ...