RE: [xsl] key() question?

Subject: RE: [xsl] key() question?
From: "Américo Albuquerque \(E-mail\)" <aalbuquerque@xxxxxxxxxxxxxxxx>
Date: Wed, 10 Jul 2002 15:39:40 +0100
Sorry for my newbie question but, given this xml
  <pattern level="1"/>
   <pattern level="2"/>
 <pattern level="1"/>

 and given this xsl

<xsl:template match="doc">

<xsl:template match="pattern">

<xsl:template match="//pattern">

doesn't the match="pattern" gets only the level=1" patterns???
and match="//patterns" get's all of them??

thanks in advance

-----Original Message-----
From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx
[mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx]On Behalf Of David
Sent: Wednesday, July 10, 2002 2:04 PM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: Re: [xsl] key() question?

> a template match is done in a given context,

> the key (as I understand it) does the full traversal of the whole
> document, as if template match="//pattern"

yes exactly, but

 template match="//pattern"

is the same (except for default priority) as
 template match="pattern"

ie such a template would match the same nodes as got indexed by a key
with the same match pattern.


This message has been checked for all known viruses by Star Internet
delivered through the MessageLabs Virus Scanning Service. For further
information visit or alternatively call
Star Internet for details on the Virus Scanning Service.

 XSL-List info and archive:

 XSL-List info and archive:

Current Thread