This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
RE: counting the number of following siblings
- From: "Michael Kay" <michael dot h dot kay at ntlworld dot com>
- To: <xsl-list at lists dot mulberrytech dot com>
- Date: Tue, 27 Nov 2001 15:43:51 -0000
- Subject: RE: [xsl] counting the number of following siblings
- Reply-to: xsl-list at lists dot mulberrytech dot com
> I am trying to write a function that tests that the current
> node is of type
> D and that the number of following D type nodes is greater
> than 3. Something
> like this:
>
> <xsl:when test="./@type='D' and
> count(following-sibling::faostat:table-row[1]/@type='D')>3">
>
Try count(following-sibling::faostat:table-row[@type='D'])
I've no idea what the [1] was doing there.
Mike Kay
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list