RE: [xsl] Multiple attributes present and non-present

Subject: RE: [xsl] Multiple attributes present and non-present
From: "Michael Kay" <michael.h.kay@xxxxxxxxxxxx>
Date: Wed, 6 Mar 2002 18:40:52 -0000
I thought that:
>
> <xsl:if test="@ENCODINGANALOG/text()"/>
>
> would do this.
>
It will always return nothing, because attribute nodes do not have children.

test="@X" will succeed if attribute X exists
test="string(@X)" will succeed if X exists and its value is not the empty
string
test="@X=''" will succeed if X exists and its value is the empty string

Michael Kay
Software AG
home: Michael.H.Kay@xxxxxxxxxxxx
work: Michael.Kay@xxxxxxxxxxxxxx


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread