[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: for-each attribute
> <inside-xsl-tag> > <xsl:for-each select="in-tag/@*"> > <xsl:attribute name="{name()}"><xsl:value-of select="."/></xsl:attribute> > </xsl:for-each> > </inside-xsl-tag> > This works fine, probably quicker (and safer if namespaces are involved) is just <inside-xsl-tag> <xsl:copy-of select="in-tag/@*"> </inside-xsl-tag> ><xsl:param name="it"/> ><inside-xsl-tag> ><xsl:for-each select="nodeset:nodeset($it)/in-xsl-tag/@*"> ><xsl:attribute name="{name()}"><xsl:value-of select="."/></xsl:attribute> ></xsl:for-each> ></inside-xsl-tag> >Xalan complains about an illegal attributes as it tries to assign the >attributes of <in-tag> to <xsl:for-each> It looks OK, assuming "nodeset:nodeset() does what I think it does. but perhaps just using copy-of as above will solve your problem anyway? Is your nodeset: namespace prefix correctly declared in your stylesheet? David XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|