[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Sibling in the Pattern(match)
Hi, I want to perform a filering out transformation to a source file. I copy most things, but leave out specfic parts. The left out part can be done like this: <xsl:template match="execluded-nodes"> "do nothing" </xsl:template> <xsl:template match="child::Member[@name ='acc1']"/> There is a problem with this approach. It seems like you only can specify "child" or "attribute" in the match pattern. What can I do if I want to execlude all the nodes having the same level as a selected nodel? For example, the selected node is "acc11", all the nodes having the same level like "acc12", "acc31", and "acc32" will be also included What can I do if I want to execlude all the sibling nodes of a selected node? For example, the selected node is "acc11", the "acc12" will be also included". Is there any good thought on this? Thanks Dongling (Source XML File) <Member comment="" name="acc1"> <Calc>+</Calc> <Member comment="" name="acc11"> <Calc>+</Calc> <Member name="account3_1"/> </Member> <Member comment="" name="acc12"> <Calc>+</Calc> <Member name="account3_1"/> </Member> </Member> <Member comment="" name="acc2"> <Calc>+</Calc> </Member> <Member comment="" name="acc3"> <Calc>+</Calc> <Member comment="" name="acc31"> <Calc>+</Calc> </Member> <Member comment="" name="acc32"> <Calc>+</Calc> </Member> </Member> __________________________________ Do you Yahoo!? Free Pop-Up Blocker - Get it now http://companion.yahoo.com/ 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
|