xsl-list
[Top] [All Lists]

Re: [xsl] XML transformation based on parameters

2009-04-16 06:34:09
Daivd,

with an external static file it works properly, but I need to pass the
xml stream at runtime... in this case what should I do?

:-/

e.


2009/4/16 David Carlisle <davidc(_at_)nag(_dot_)co(_dot_)uk>:


is: is there a way to encode this xml file in some way
and see it as a normal xpath variable?

no doubt there will be, but the simplest way may well be but if you do
this:

document($params)/

then you avoid the need to  build teh document tree externally and pass
it i, you just need "parsms" to be a string with a value like
"myfile.xml"
then the xslt document function will handle parsing teh xml and
returning a node set.

Get it working using a fixed string first

document('myfile.xml')/query-params/param/@name"

then if you need to make the file name a global parameter do that
afterwards.

David

________________________________________________________________________
The Numerical Algorithms Group Ltd is a company registered in England
and Wales with company number 1249803. The registered office is:
Wilkinson House, Jordan Hill Road, Oxford OX2 8DR, United Kingdom.

This e-mail has been scanned for all viruses by Star. The service is
powered by MessageLabs.
________________________________________________________________________

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: 
<mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--



--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--