Getting the number of levels

topic posted Wed, January 21, 2004 - 9:30 PM by  Manny
Hello, everyone (=

Have a teenie weenie question. Say I have the following XML doc:

<root>
<child>
<child>
<child></child>
</child>
</child>
</root>

With XPath v1.0, is there a way to determine how many levels there are for "child" node (in this case 3)? I could think of some other ways of determining it like creating a custom XSLT function (except custom functions is for XLST 2 and the program I'm using is implementing XLST v1.0) so I was wondering if somewhere in the XPath recommendation lies an easier answer :D


--
I'm blind, where's the edit function for the discussion board?
posted by:
Manny

Recent topics in "XML & XSLT"