Hello, XSLT Wizards, I thought I understood position() in predicates, but my self- confidence has been shaken by the following -- <xsl:when test="preceding-sibling::*[starts-with(name(),'div')][position()=1]"> The question is: Is this statement true only when the immediately preceding sibling is a div or is it also true when there are any div preceding siblings? If the latter, then how do I select the first div preceding sibling, skipping any non-div siblings? Does <xsl:value-of select="preceding-sibling::*[starts-with(name(),'div')][position()=1]"/> do the trick? If so, then the [position()=1] part of the predicate behaves differently when used with 'test' than with 'select', no? I'm soooo confused. -- perry XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
PURCHASE STYLUS STUDIO ONLINE TODAY!
Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!
Download The World's Best XML IDE!
Accelerate XML development with our award-winning XML IDE - Download a free trial today!
Subscribe in XML format