Subject: [xsl] XPath expr on generated nodeset From: "Al Byers" <byersa@xxxxxxxxxxxxxxxxxxxx> Date: Fri, 25 Oct 2002 08:28:00 -0600 |
I generated a nodeset by assigning elements to a variable and then converting the fragment to a nodeset, but normal XPath expressions do not seem to work. I would appreciate any help on figuring out what I am doing wrong. I am using Xalan 2.4.0. TIA Al <xsl:stylesheet exclude-result-prefixes="xalan" version="1.0" xmlns="automationgroups.com/docdebug" xmlns:xalan="http://xml.apache.org/xalan" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:template match="/"> <xsl:variable name="aFrag"> <xsl:element name="aaa"> <xsl:element name="bbb">Stuff</xsl:element> </xsl:element> </xsl:variable> <xsl:variable name="aNd" select="xalan:nodeset($aFrag)"/> <xsl:element name="out"> <!-- This generates output --> <xsl:element name="one"> <xsl:copy-of select="$aNd[1]/*[1]"/> </xsl:element> <!-- but this does not --> <xsl:element name="two"> <xsl:copy-of select="$aNd//bbb"/> </xsl:element> </xsl:element> </xsl:template> </xsl:stylesheet> Al Byers Wasatch Automation Group, LLC P.O. Box 1672 Orem, UT 84059 801.400.5111 byersa@xxxxxxxxxxxxxxxxxxxx http://automationgroups.com/na/wasatch XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] msxsl:script with VBScrip, Jeff Beadle | Thread | Re: [xsl] XPath expr on generated n, David Carlisle |
Re: [xsl] too many columns, Gabi Bucataru | Date | RE: [xsl] msxsl:script with VBScrip, Jeff Beadle |
Month |