[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Global variables and changing within templates

Subject: Re: Global variables and changing within templates
From: Steve Tinney <stinney@xxxxxxxxxxxxx>
Date: Wed, 09 Feb 2000 23:23:26 -0500
word change variable in template
> If I define a global variable, how can I pass it to a template, change
> it within the template, and be able to access the new value for the
> variable after the template processing is complete ?

There are two answers here.  (1) You can't.  You need to learn how to
use recursion to achieve the desired effects.  (2) You can if you use an
extension mechanism like saxon:assign; that depends on your XSL
processor.

I'm not going to engage in gross generalizations about the necessity of
saxon:assign and the like, but I have yet to encounter a problem that I
couldn't solve without it, including writing an XSL word-counting
script.

To turn one's back on problem-solving with modifiable variables, and to
know recursion, is to know XSL.

 Steve


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


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.