I have a an xsl stylesheet that loads a document such as:
<xsl:variable name="sb" select="document('data.xml')/root"/>
the Data xml looks something like
<root>
<function name='Test'>
<data1>data<data1>
</function>
</root>
I would like to address this later in the xsl document by selecting a node such as
<xsl:variable name="function_name" select="$sb/root/function/@name"/>
This always returns nothing. Infact so does $sb/root or $sb/root/function
I can expand the variable in xmlspy when the debugger stops at the location I am trying to use the xpath and it all looks correct. Have you any idea what I am doing wrong?
Note: The XPath doesn't work in the xmlspy debugger watch either.
<xsl:variable name="sb" select="document('data.xml')/root"/>
the Data xml looks something like
<root>
<function name='Test'>
<data1>data<data1>
</function>
</root>
I would like to address this later in the xsl document by selecting a node such as
<xsl:variable name="function_name" select="$sb/root/function/@name"/>
This always returns nothing. Infact so does $sb/root or $sb/root/function
I can expand the variable in xmlspy when the debugger stops at the location I am trying to use the xpath and it all looks correct. Have you any idea what I am doing wrong?
Note: The XPath doesn't work in the xmlspy debugger watch either.