Here is my XSLT file:
<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="/">
<xsl:value-of select="a/b" />
</xsl:template>
</xsl:stylesheet>
Here is my XML file:
<a><b>four < five</b></a>
I would like the output
four < five
but I get
four
Clearly there is a problem with XSLT understanding the < entity. I have read this question
but do not find it quite relevant because it pertains to the xsl:text tag, whereas I am interested in the xsl:value-of tag.
By the way, I am unable to modify the XML file.
<character should be there but browser understood it as a broken markup.four < five, so that my browser can then producefour < five.<?xml version="1.0" encoding="utf-8"?>four < five.<a><b>four &lt; five</b></a>you will should get your expected output, although this is not the correct thing to do!). Try it at xmlplayground.com or xsltransform.net and you will see there is actually no problem with your code at all.