I am forming an xsl where I am forming a map with keys and values.
<java:map>
<entry key="10001">2.1</entry>
<entry key="48201">3.1</entry>
<entry key="11215">4.1</entry>
<entry key="28201">5.1</entry>
<entry key="60601">6.1</entry>
</java:map>
<xsl:template match="/">
<!-- <output>
<xsl:value-of select="document('')/*/java:map/entry[@key='10001']"/>
</output> -->
<xsl:variable name="zipCodeString" select="./PersonInfoShipTo/@ZipCode"/
<xsl:value-of select='$zipCodeString' /> // giving value of 10001
<xsl:value-of select="document('')/*/java:map/entry[@key='$zipCodeString']"/> // not displaying any thing.
</xsl:template>
As mentioned in the comments, I was using a variable which will get a value of 10001, I would like to use that to retrieve value in the next statement i.e., dynamically
Not able to understand , the syntax how to do that . Please advice
using exclude-result-prefixes="java"
Regards Suresh Midde