This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: generic apply-template call


> if you have a DTD you could use id() and then you just need to make
> sure that your 2key" attributes are declared ID and have distinct
> values.

If not then it depends what you mean by

> Is there a way to make the use attribuite of xsl:key select a particular 
> value?  If so, then this could be the droid we are looking for.

you could for example use

<xsl:key name="x" match="*" use="@*"/>

then you could go

<xsl:apply-templates select="key('x','unique.key')"/>

if 'unique.key' is sufficiently unique or, equivalent to what you had
originally you could go
<xsl:apply-templates select="key('x','unique.key')[@key='unique.key']"/>


maybe you don't want @* but something like
<xsl:key name="x" match="*" use="@key|@key-b|@key-c"/>

David

_____________________________________________________________________
This message has been checked for all known viruses by Star Internet
delivered through the MessageLabs Virus Scanning Service. For further
information visit http://www.star.net.uk/stats.asp or alternatively call
Star Internet for details on the Virus Scanning Service.

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]