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

Re: ../preceding-sibling/SubDiv1" does not seem to wor

Subject: Re: ../preceding-sibling/SubDiv1" does not seem to work
From: Fred Christian <fredc@xxxxxxxxxx>
Date: Mon, 09 Mar 2009 13:08:40 -0700
Re:  ../preceding-sibling/SubDiv1" does not seem to wor
I believe my current context to be inside the second <level2>since value-of select="SubDiv1" gives me the contents of the second SubDiv1.
1st, both of your <SubDiv1>'s are the same, so the value-of doesn't work, But in case this is a typo and you meant.
"since value-of select="SubDiv2" gives me the contents of the second SubDiv2


Then I think you want. (preceding-sibling::Level2/SubDiv1 = SubDiv1) instead of (../preceding-sibling/SubDiv1 = SubDiv1)

This assumes there are no other <Level2> nodes in the preceding-sibling axis. To handle that condition, you could try this
(preceding-sibling::Level2[1]/SubDiv1 = SubDiv1)
I now want to know if the two SubDiv1 elements are identical or different. I tried ../preceding-sibling/SubDiv1 = SubDiv1, but the first part of the expression does not work. What have I misunderstood?
Thanks,
Mark
If that doesn't work, I would have to see more of the surrounding xslt.

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.