Subject: Re: [xsl] How to query a temporary document in a variable From: Martin Honnen <Martin.Honnen@xxxxxx> Date: Mon, 10 Sep 2012 14:47:38 +0200 |
Hello xslt-users
I'm trying to use a temporary document as a lookup table with saxon 9.4 using xslt 2.0. The solution is also proposed in this stackoverflow answer: http://stackoverflow.com/questions/3626118/xslt-creating-a-map-in-xslt
But I'm not getting any results when I query the variable that holds the temporary document:
<xsl:variable name="propertyMap"> <entry key="foo">foo value</entry> <entry key="bar">bar value</entry> </xsl:variable>
<xsl:template match="/"> <xsl:value-of select="$propertyMap/entry[position() = 1]"/> <xsl:value-of select="$propertyMap/entry[@key='foo']"/> <xsl:value-of select="$propertyMap[1]"/> </xsl:template>
The first two value-of expressions do not output anything, whereas the third one outputs the whole propertyMap.
Any idea what I'm missing here?
Martin Honnen --- MVP Data Platform Development http://msmvps.com/blogs/martin_honnen/
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] How to query a temporary , Andrew Welch | Thread | Re: [xsl] How to query a temporary , Jean-Pierre Bergamin |
Re: [xsl] How to query a temporary , Andrew Welch | Date | Re: [xsl] How to query a temporary , Jean-Pierre Bergamin |
Month |