Thankyou very much Charles.
I was able to set parameter in my xalan version with out problem. Could you please give a simple example how i retrieve this paramater in xsl and use it. I appreciate your help.


Thanks
Anand


----Original Message Follows----
From: Charles Yates <[EMAIL PROTECTED]>
To: Anand <[EMAIL PROTECTED]>
CC: [EMAIL PROTECTED]
Subject: Re: Any help
Date: Wed, 26 Sep 2001 14:17:58 -0700
MIME-Version: 1.0
Received: from [64.125.133.20] by hotmail.com (3.2) with ESMTP id MHotMailBD7B948E00574004318A407D851409930; Wed, 26 Sep 2001 14:33:03 -0700
Received: (qmail 77361 invoked by uid 500); 26 Sep 2001 21:21:39 -0000
Received: (qmail 77351 invoked from network); 26 Sep 2001 21:21:39 -0000
Received: from lanelib.stanford.edu (171.65.81.117) by daedalus.apache.org with SMTP; 26 Sep 2001 21:21:39 -0000
Received: from lanelib.stanford.edu (lane-ts-yatesnt.Stanford.EDU [171.65.82.249])by lanelib.stanford.edu (8.8.8/8.8.8) with ESMTP id OAA29765;Wed, 26 Sep 2001 14:21:42 -0700 (PDT)
From xalan-j-users-return-120-anandtd Wed, 26 Sep 2001 14:33:24 -0700
Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm
Precedence: bulk
list-help: <mailto:[EMAIL PROTECTED]>
list-unsubscribe: <mailto:[EMAIL PROTECTED]>
list-post: <mailto:[EMAIL PROTECTED]>
Delivered-To: mailing list [EMAIL PROTECTED]
Message-ID: <[EMAIL PROTECTED]>
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.3) Gecko/20010816
X-Accept-Language: en-us
References: <[EMAIL PROTECTED]>
X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N


Hi,
      I like jaxp: http://java.sun.com/xml/jaxp.html

used like this:

import javax.xml.transform.stream.*;
import javax.xml.transform.*
import java.io.*;
import javax.servlet.http.*;

StreamSource stylesheet = new StreamSource(new File("/path/to/stylesheet.xsl"));
Transformer transformer = TransformerFactory.newInstance().newTransformer(stylesheet);
transformer.setParameter("parameterName","parameterValue");
transformer.transform(new StreamSource(new File("/path/to/xml.xml")), new StreamResult(response.getWriter());


If your version of xalan knows about jaxp (recent versions do) and is in your
classpath at run time, xalan will be used. It is nice because it removes
dependancy of your code on a particular xslt implementation.


Charles

Anand wrote:
> I am new to this xalan and xslt world. Any help is very much appreciated.
>
>
>
> I am working on a web application development using jsp/servlets and may
> be ejbs.
>
> We are inclined towards using xml/xslt for some data independencies.
>
> I wonder can we write xslts which take some parameters from caller
> (could be jsp/servlet) and transforms the xml accordingly?
>
> Is this possible if i use xalan? Any simple examples are very much
> appreciated. I also wonder if there are any resources on web for
> reference on application development using xalan/jsp/servlets.
>
>
>
> Thanks
>
> Anand
>






_________________________________________________________________ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp



Reply via email to