This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[XPath] Type of the first child


Hi all,

I have an XPath question, really. In a pattern, I want to take a different
action if the first child of my element is a text node or an element. I
wrote the following predicate, which is to be true if the first child is a
text node:

	not(name(*[1]))

It seems to work, but is this correct? Is there a better way to write this?
Thanks -- Julien

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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]