|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] problem with Xpath in Variable filled by choose
I have written following Code:
I use XSL v 2.0 and transform it with a JavaScript transformer:
<xsl:variable name="CategoryPointer">
<xsl:choose>
<xsl:when test="$category = 'main'">
<xsl:copy-of
select="document('style.xml')/root/DeviceParameters/DesignMood/Category/main
"/>
</xsl:when>
<xsl:when test="$category = 'news'">
<xsl:value-of
select="document('style.xml')/root/DeviceParameters/DesignMood/Category/news
"/>
</xsl:when>
</xsl:choose>
</xsl:variable>
<xsl:value-of select="$CategoryPointer/HeadlineColor"/>
<xsl:value-of select="$CategoryPointer"/>
My Problem is here:
<xsl:value-of select="$CategoryPointer/HeadlineColor"/>
This row should give me Output of a Node in my XML File there ->
('style.xml')/root/DeviceParameters/DesignMood/Category/main/HeadlineColor
But it seems that here in this following part my Xpath that should be saved
in the variable CategoryPointer is transformed into a String in this Lines:
<xsl:variable name="CategoryPointer">
<xsl:choose>
<xsl:when test="$category = 'main'">
<xsl:copy-of
select="document('style.xml')/root/DeviceParameters/DesignMood/Category/main
"/>
</xsl:when>
So my question: How can I handover a Node to this Variable instead of a
String?
Thanks for you Help
Dietmar
|
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
|

Cart








