Subject: Re: [xsl] stylesheet params and parsing a (MathML) string From: Manolis Mavrikis <M.Mavrikis@xxxxxxxx> Date: Mon, 24 Nov 2003 01:16:51 +0000 |
[...]but then you'd have to declare that namespace again to match on the elemens so simpler is probably to put them all in no-namespace xsl:element isn't needed if your element names are known in advance so I'd use literal result elements and locally switch the default namespace so instead of
do
<xsl:variable name="tree" xmlns="">
<myTree id="{$param1}">
<xsl:value-of select="$param2"/>
</myTree>
</xsl:variable>
that seems a better solution ...If $param2 is a string thaen as you say you'll need a parser. some systems (eg saxon) provide extension functions to parse a string (and in msxml you could easily write an jscript extension function to do this) alternatively (and better in many cases) is to pass a node set representing a parsed document in as the parameter then you can apply templates directly to it and dont need nodeset() at all.
Yousualy you can't do this from a command line call but can do it if youthe stylesheet **will be called from a java.xml tranformer and xalan will process it. I 'll try do it later and I hoping that xalan will understand the node parameter... meanwhile if anyone has any advice (eg. what java object should I send?) it would be very useful.
are calling xslt from any kind of script or API.
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] stylesheet params and par, David Carlisle | Thread | [xsl] Sibling in the Pattern(match), Dongling Ding |
Re: [xsl] multi-document question, Bruce D'Arcus | Date | [xsl] Sibling in the Pattern(match), Dongling Ding |
Month |