xsl-list
[Top] [All Lists]

Re: Converting <xml> StyleSheet param contents into a node set?

2005-08-16 23:38:21
Well, I spoke too soon on this.  For some reason the returned
nodeset() or lack there of won't let me traverse the tree accordingly:

...
Stylesheet: ( Filter=<Node><Value/>HI</Value></Node> )
...
<xsl:param name="Filter" select="0" />

<xsl:variable name="rtf">
  <xsl:value-of select="$Filter" disable-output-escaping="yes"/>
</xsl:variable>
<xsl:variable name="rtf2" select="xalan:nodeset($rtf)" />
                                        
<xsl:for-each select="($rtf2)/Value">           <!-- Not returning Value here?? 
-->     
   <xsl:element name="IncomingValue">   
      <xsl:copy-of select="."/>
   </xsl:element>
</xsl:for-each>

Does anybody have an idea as to what I'm doing wrong here?

Thanks in advance!

On 8/17/05, Jacquo Johnson <genxgeek(_at_)gmail(_dot_)com> wrote:
Looks like this works (since I'm pigeon holed using xalan)..
...
<xsl:variable name="rtf">
   <xsl:value-of select="$Filter" disable-output-escaping="yes"/>
</xsl:variable>

<xsl:copy-of select="xalan:nodeset($rtf)" />
...

Is there a better way to do this than with xalan:nodeset() or any
equivalent node-set()/nodeset() entension function?

--
On 8/16/05, Jacquo Johnson <genxgeek(_at_)gmail(_dot_)com> wrote:
HI all, can somebody tell me how I can pass <xml> contents into a
stylesheet param and then convert that <xml> contents into a nodeset?


Stylesheet: ( Filter=<Node><Whatever/></Node> )
...
<xsl:param name="Filter" select="string('NULL')" />

   <xsl:copy-of select="$Filter"/>
...
Output:
   &lt;Node&gt;&lt;Whatever/&gt;&lt;/Node&gt;

However, I want to turn the xml contents above into a node set that I
can later use in the transform.  Is that possible (is there something
other than using CDATA)?

Any information would be greatly appreciated.



--~------------------------------------------------------------------
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>
--~--