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 expression - select first node from last parent




Hi,

I would like an generic Xpath expression that will match the first child of
a parent that is positionally last.

For example, using this highly descriptive piece of ascii art:

     a---a---a---a---a
                     |
                     b---b---b---b
                     ^

All 'b' elements are children of the last 'a' element.  I want to be able to
recognise when Im at the first b of the last 'a'.

Something like:

*[position()=1]

and

parent::*[postion()=last()]

combined.


cheers

andrew

===



 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]