[Home] [By Thread] [By Date] [Recent Entries]
Mark Anderson schrieb:
In my output, I need to differentiate between node1/name and node2/name. Is there a way to get the full path of the current element so I output contains the path as well as the element name? Yes, see my second post to this thread. Secondly, if a node has children, the entire RTF is tested.
is there a way to omit RTF's containing more than one node
<xsl:template match="*[*]">
<xsl:apply-templates select="*|@*"/>
</xsl:template>This will match element nodes containing other element nodes, not generate any output but simply carry on processing down the tree. Note, however, that differences involving mixed content (element and text nodes interspersed) will escape your notice if you adopt this approach. Let's say there is an element that has other element children but also text children, and there is a difference in the text children with regard to your reference document. This difference won't get detected; you'd need something more refined here. If you know, on the other hand, that you don't have mixed content there is no problem. Michael Ludwig
|

Cart



