xsl-list
[Top] [All Lists]

Re: Assigning Values to Global Parameter

2003-09-23 13:24:47
Easy. <xsl:with-param/>. You can only use it inside <xsl:apply-templates/>
or <xsl:call-template>, but that's not really much of a problem in terms of
design.

For consistency, I always declare my global parameters like this:
<xsl:parameter select="'optional_default_value'"></xsl:parameter>. A value
assigned later with <xsl:with-param/> takes precedence over the value of the
"select" attribute.

It sounds like you may be confusing global parameters with global variables,
which can only have the initial assigned value.

-- Brook

From: "James Paul" <jpaul(_at_)quadrem(_dot_)com>
Reply-To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Date: Tue, 23 Sep 2003 14:31:33 -0500
To: <xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com>
Subject: [xsl] Assigning Values to Global Parameter

If I set up a global parameter and the value is blank, how do I assign a
value later in my mapping?  And if you can't is there a better way to do
the above scenario.

Thanks,
James Paul

XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list




 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



<Prev in Thread] Current Thread [Next in Thread>