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

Re: Passing parameters to xsl

Subject: Re: Passing parameters to xsl
From: "Joseph Alex" <alex_jos@xxxxxxxxxxx>
Date: Sat, 01 May 1999 05:52:40 PDT
parameters in xsl

I had this problem sometime back and these are my solutions to this problem. Am not sure whether this would solve your problems or whether they are absolutely correct. Anyway here it goes..

I am using IE5, IIS etc, for both client and server side combination of XML and XSL using ASPs. Since the XSL is used only during transformation, you really can't pass parameters to XSL. The only way to counter this would be dynamically generate XSL based on the requirements or have multiple XSLs ready if that is feasible, both of which I have tried successfully. Another way which I used extensively in my program was to manipulate the XML DOM using the ASP scripts. Depending on the parameter or whatever, when ASP processes XML and XSL, I appended a child node to the XML DOM object and the XSL has the code in it to check which parameter it has etc and do the necessary action. And of course, XSL can certainly call the functions in the ASP later which could alter the DOM, or whatever. In fact, I implemented client side and server side sorting entirely doing this.

Hope this helps. I don't think there is a more direct way to do this, if anybody knows of any, please let me know.


From: Sunil Jain <sujain@xxxxxxxxx>
Reply-To: xsl-list@xxxxxxxxxxxxxxxx
To: XSL-List@xxxxxxxxxxxxxxxx
Subject: Passing parameters to xsl
Date: Fri, 30 Apr 1999 14:01:35 -0600


is there any way to pass paramters to xsl so that it will behave differently based on input parameters.
for example if I have following xml :
<customer id="1">
<customer id="2">
<customer id="3">

Now I want to generate three different html based on the parameter (1,2,3) one for each customer id(1,2,3)

Thanks in advance for responses.


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

Get Your Private, Free Email at http://www.hotmail.com

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

Current Thread


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.
First Name
Last Name
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.