[XSL-LIST Mailing List Archive Home]
[By Thread]
[By Date]
Re: [xsl] Applying templates for unique children
Subject: Re: [xsl] Applying templates for unique children From: David Carlisle <davidc@xxxxxxxxx> Date: Mon, 4 Aug 2003 21:40:24 +0100 |
Why don't I just use the Muenchian method again? Because there are <definition> elements that have the same value under a different root/sequence so the first element in the key may not be the same as the one in the current node, e.g.: The trick is to generate a key expression that distinguishes what you want distinguished. In this case that's a combination of sequence and definition so for your second level key do <xsl:key name="x" match="definition" use="concat(../sequence,'@',.)"/> and use a similar concat in your key() lookup. This assumes that '@' is a safe separator (ie doesn't appear in your definitions) if it is not suitable there must be some unicode character to hand that isn't used in your data. David XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] Applying templates for unique, Elizabeth Barham | Thread | [xsl] How to process individual val, Néstor Boscán |
[xsl] How to process individual val, Néstor Boscán | Date | RE: [xsl] Using copy to change a no, John Reid |
Month |
Keywords