This is the mail archive of the
mailing list .
Re: simple XPath question
> Thank you both, these XPath expressions produce the desired result. Your
> explanations (and Jeni's) were quite helpful.
> The nominal purpose of this example given in Fung's book (in which it
> as far as I can tell) is to demonstrate template priority, and that
> <xsl:template match='country'> has a higher priority than <xsl:template
> match='country'>. Accordingly, the solution Thomas Passin and Jeni
> posed of using <xsl:when
> test='position()=1'><first-country>...</first-country></xsl:when> ...
> a template matching 'country' is contrary to the purpose of the example,
> though it is certainly a viable approach.
Well, it looks like he succeeded in demonstrating the point, since the
country template always got called, but the results weren't what anyone
would actually have wanted.
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list