Quantcast
Channel: Detecting if a node exists? - Stack Overflow
Browsing latest articles
Browse All 4 View Live

Answer by Hrvoje Golcic for Detecting if a node exists?

This will work with XSL 1.0 if someone needs...<xsl:choose><xsl:when test="/testdata">node exists</xsl:when><xsl:otherwise>node does not...

View Article



Answer by Flack for Detecting if a node exists?

This XSLT:<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"><xsl:output method="text"/><xsl:template match="text()"/> <!-- for clarity only...

View Article

Answer by Alex Nikolaenkov for Detecting if a node exists?

Try count(.//testdata) &gt; 0. However if your context node is textdata and you want to test whether it has somenode child or not i would write:<xsl:if test="somenode"> ...</xsl:if>But...

View Article

Detecting if a node exists?

I have a set of data called <testData> with many nodes inside.How do I detect if the node exists or not? I've tried<xsl:if test="/testData">and<xsl:if test="../testData">Neither one...

View Article
Browsing latest articles
Browse All 4 View Live




Latest Images