Re: [xsl] XSL/XPath to generate a list of ancestors?

Subject: Re: [xsl] XSL/XPath to generate a list of ancestors?
From: Florent Georges <lists@xxxxxxxxxxxx>
Date: Sat, 17 May 2008 19:56:56 +0200 (CEST)
Martin Honnen wrote:


> >>>      <xsl:template match="*" name="fullNameWorker"
> >>>        mode="fullName">

> >> You have a template for element nodes (match="*") so why do
> >> you test
> >>   generate-id(.) != generate-id(/)
> >> ? An element (.) is never a root node (/).

> > Because the template recursively ascends the document I need to
> > test that I have arrived at the top.

> But your template with match="*" is never processed for the root
> node which is match="/".

  This message was posted a few days ago, but I didn't see any response
to that, so just for the sake of comprehensiveness in the archive...

  I didn't looked at the details of the template, but having match="*"
is not enough to garantee that the context item is an element, when the
template has also a name.  This is one reason to try to avoid having
named template rules IMHO.



Do You Yahoo!?
En finir avec le spam? Yahoo! Mail vous offre la meilleure protection possible contre les messages non sollicitis Yahoo! Mail 

Current Thread