Re: [xml] query - append DOM tree, identify leaf node



Lars Oppermann wrote:
With leaf node I assume you mean an element node that has only text or attribute children but no other element children. A way of doing this in XPath is like this:

//*[count(./*)=0]

Which of course is equivalent to

//*[count(*)=0]

As I realized shortly after pressing the send button ;)




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]