Subject: Re: [xsl] Merging data based on attributes From: "Bob Portnell" <simply.bobp@xxxxxxxxx> Date: Wed, 23 Aug 2006 10:36:28 -0700 |
This seems to do what you need:
<xsl:key name="element" match="element" use="../@id"/> <xsl:key name="phase" match="phase" use="../@id"/>
Then we look at any <text> child of <svg> than has the strings 'element' or 'phase'...
<xsl:template match="svg:text[.=('element','phase')]">
<text>
<xsl:copy-of select="@*"/>
<xsl:value-of select="key(.,../@id,doc('textsrc.xml'))"/>
Use the key corresponding to the node we're in ... and the @id of this node's parent ... and I can see the example in the XSLT 2.0 CR that this is emulating, but I'm just not understanding the roll of that third element in the key function. Obviously, that's where it's getting the other data and dropping it in.
BobP simply.bobp@xxxxxxxxx
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Merging data based on att, David Carlisle | Thread | Re: [xsl] Merging data based on att, David Carlisle |
RE: Re: [xsl] Java program to Gener, cknell | Date | RE: [xsl] Java program to Generate , Michael Kay |
Month |