Subject: Re: [xsl] xsl:key match all values From: Mukul Gandhi <mukul_gandhi@xxxxxxxxx> Date: Mon, 28 Mar 2005 11:14:23 -0800 (PST) |
Hi Karl, I think this can be done without keys, using XPath only.. <xsl:copy-of select="//BBB[@t='1']/child::*" /> (if there is only one node BBB t='1') , or <xsl:copy-of select="(//BBB[@t='1'])[1]/child::*" /> (if there are multiple BBB t='1' nodes; this selects the 1st match) // may not be necessary if you want to operate at a particular context node. (this is not tested) Regards, Mukul --- Karl Stubsjoen <kstubs@xxxxxxxxx> wrote: > Hello, > > How do you setup a key that simply matches all child > elements from the > match? Given: > > <AAA> > <BBB t="1"> > <CCC s = "1"/> > <CCC s = "2"/> > <CCC s = "3"/> > <CCC s = "4"/> > <CCC s = "5"/> > <CCC s = "6"/> > </BBB> > <CCC> > <BBB r = "a"/> > <BBB r = "b"/> > <BBB r = "c"/> > </CCC> > <BBB/> > <BBB/> > </AAA> > > > I just want to return all child elements of BBB > t='1'. > So results would be: > > <CCC s = "1"/> > <CCC s = "2"/> > <CCC s = "3"/> > <CCC s = "4"/> > <CCC s = "5"/> > <CCC s = "6"/> > > > Karl > > __________________________________ Do you Yahoo!? Yahoo! Small Business - Try our new resources site! http://smallbusiness.yahoo.com/resources/
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] xsl:key match all values, Wendell Piez | Thread | Re: [xsl] xsl:key match all values, Karl Stubsjoen |
Re: [xsl] xsl:key match all values, Wendell Piez | Date | Re: [xsl] xsl:key match all values, Karl Stubsjoen |
Month |