We have, for example, the following XML (muchos simplified)
<nodes>
<node>
<childnode>value</childnode>
<node>
<nodes>
This is a little unfortunate but unavoidable as the data is a string and the xml object builder can't tell the difference between a normal string and one that should be real XML. Only the XSLT knows this (long story).
What I need to do is parse this in XSLT as normal and access the XML and it's values, children, attributes etc stored in the string? For example the Xpath might read "/nodes/node/childnode" I've tried putting it in variables with and without output-escaping disabled and so on without success. Anybody know of a way to do this?
We're using MSXML3. Any help would be greatly appreciated.
The < is a result of encoding that happens when we put a string from a DB into an XML node. We can't do much about this at present.
I need to convert the string into XML inside the XSLT that the same XSLT can then parse in the same go... example of what I thought might work:
XML<nodes>
<node>
<childnode>value</childnode>
</node>
</nodes>XLST
<xsl:variable name="myStringXML">
<xsl:value-of select="/nodes/node"/>
</xsl:variable><xsl:for-each select="$myStringXML/childnode">
<xsl:value-of select="."/>
</xsl:for-each>
It didn't - even thought the
<xsl:value-of select="/nodes/node"/>returns the value without the <s etc it's still a string. What I need is somekind of xml() function that turns a string into a real nodeset.
PS. If you want to avoid using ENTITY just for you can use   instead.