[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: XPath selection using //

Subject: RE: XPath selection using //
From: "Andrew Welch" <awelch@xxxxxxxxxxxxxxx>
Date: Wed, 17 Jul 2002 16:49:11 +0100
xpath difference following following sibling
>>   Attribute a of the following m is: <xsl:value-of
>>select="following::m/@a"/>
>> </xsl:template>
>>
>>The 'following-sibling' axes will only match nodes of the same depth 
>>of the xml document. 
>
>Somehow I've managed not to see the "following" axis in the
documentation.
>It's working perfectly now.


note there's a big difference between the following:: axis and the
following-sibling:: axis


>'following-sibling' axes will only match nodes of the same depth 

following-sibling will select all the nodes that appear after the origin
node in document order, with the same parent, not nodes of the same
depth in the tree (which could have different parents)

Mike Kays book has some nice diagrams on pages 364-367 (2nd ed) to help
you visualise this

cheers
andrew


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.373 / Virus Database: 208 - Release Date: 01/07/2002
 

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


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.