You're welcome. For the record, I made a typo when left out the closing square
bracket in the predicate. Here is the correct template:
<xsl:template match="BROTHER">
<xsl:value-of select="count(preceding-sibling::*[name()='BROTHER'])" />
</xsl:template>
--
Charles Knell
cknell(_at_)onebox(_dot_)com - email
-----Original Message-----
From: John C Cartwright <John(_dot_)C(_dot_)Cartwright(_at_)noaa(_dot_)gov>
Sent: Fri, 09 Jul 2004 13:29:36 -0600
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: Re: [xsl] finding position in list of siblings
works perfectly! Thanks for the prompt response.
-- john
cknell(_at_)onebox(_dot_)com wrote:
Try this template:
<xsl:template match="BROTHER">
<xsl:value-of select="count(preceding-sibling::*[name()='BROTHER')" />
</xsl:template>
--
==================================================== John Cartwright
Associate Scientist
Geospatial Data Services Group
CIRES, National Geophysical Data Center/NOAA
(303) 497-6284
John(_dot_)C(_dot_)Cartwright(_at_)noaa(_dot_)gov
====================================================
--+------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--+--