[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

Re: [xsl] XPath shorthand


Subject: Re: [xsl] XPath shorthand
From: Andrew Welch <andrew.j.welch@xxxxxxxxx>
Date: Tue, 21 Aug 2012 18:12:19 +0100

On 21 August 2012 17:49, Ihe Onwuka <ihe.onwuka@xxxxxxxxxxxxxx> wrote:
> I'm assuming/hoping that the positional predicate in the match pattern
> will curtail the search when the key is being indexed since all I want
> is a list of element names.
...
>> In the end I went with
>>
>> <xsl:key name="desired_fields"
>> match="m__id[1]|m__name[1]|m__path[1]|m__enabled[1]"
>> use="local-name()"/>
>>
>> and
>>
>> following-sibling::*[key('desired_fields',local-name())]

Why do that?


-- 
Andrew Welch
http://andrewjwelch.com


Current Thread