[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

[xsl] How to test if existing tag/node contains a non-whitespace value?


Subject: [xsl] How to test if existing tag/node contains a non-whitespace value?
From: "Ben Stover" <bxstover@xxxxxxxxxxx>
Date: Wed, 09 Dec 2009 19:38:00 +0100

Assume a template matches a input tag like

<aaa>(0 or more whitespaces)</aaa>

How can I test if this node contains a non-whitespace value?
It should be something similar to:

<xsl:if test="aaa=''">
Found a value
</xsl:if>

or

<xsl:if test="normalize-space(aaa)">
Found a value
</xsl:if>

Ben


Current Thread