This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
Re: can one pass a parameter when opening an xml file?
- To: xsl-list at mulberrytech dot com
- Subject: Re: can one pass a parameter when opening an xml file?
- From: John Gethoefer <johng at sportsmvp dot com>
- Date: Thu, 03 Aug 2000 09:47:09 -0700
- References: <DBF5834E2987D311A4BE0060081D992C2C3DD6@BUR2>
- Reply-To: xsl-list at mulberrytech dot com
Hi Eric:
From my understanding (can't tell what parser you will be using) usually
you instanciate the xsl transformation process by telling the parser which
XML file and which XSL stylesheet to use. In many cases, the XML document
defines which stylesheet to use on the client-side.
If you are talking about adding data to the XML doc (passing a parameter
to it) then you need some sort of service to handle this before XSL
transformation.
If both XML docs. have the same node-sets, but you want different results
then you would use different stylesheets or use a dynamically-generated
XSL stylesheet, which would again require another service.
I think a good starting place would be to structure your data in a way
that you keep your apples with apples and oranges with oranges.
-johnG
Eric Taylor wrote:
> Perhaps just a bizarre idea (novices are good on this front), but is it
> possible to add a parameter when opening an xml file so that I can do
> something different in the XSL depending on what the parameter is? e.g.
> filename.xml A vs. filename.xml B and then in the XSL do something like
> <xsl:if parameter1="A">...<xsl:if> <xsl:if parameter1="B">...<xsl:if>
>
> XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list