Hi i have a strange issue with matching specific attribute of xml node. Example code that doesnt work:
<xsl:for-each select="../../unit/service/price/season[@name=$period_name]">
<xsl:attribute name="std_bed_price">
<xsl:value-of select="../@amount"/>
</xsl:attribute>
</xsl:for-each>
Example code that DOES work but i don't like this way too much:
<xsl:for-each select="../../unit/service/price/season">
<xsl:if test="@name = $period_name">
<xsl:attribute name="std_bed_price">
<xsl:value-of select="../@amount"/>
</xsl:attribute>
</xsl:if>
</xsl:for-each>
If in first example i replace the variable name with some of the values like 'A' it works, i also tested what variable name is selected and it has the correct data inside (so, 'A','B','C' ...)
Anyone had this problem before?
Tnx