xsl-list
[Top] [All Lists]

RE: How to count attributes?

2002-11-25 04:07:24
count(element/@atrr)

Michael Kay
Software AG
home: Michael(_dot_)H(_dot_)Kay(_at_)ntlworld(_dot_)com
work: Michael(_dot_)Kay(_at_)softwareag(_dot_)com 

-----Original Message-----
From: owner-xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com 
[mailto:owner-xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com] On Behalf Of 
Sorin Marti
Sent: 25 November 2002 10:23
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: [xsl] How to count attributes?


Hi all,

I'd like to count the number of one attribute. How can I do that?

example:

<element atrr="bla">...</element>
<element atrr="blu">...</element>
<element atrr="ble">...</element>
<element atrr="bli">...</element>
<element atrr="blo">...</element>

The result should be: 5 (because the attribute attr exists 5 times)

Thanx for help
mas


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list




 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



<Prev in Thread] Current Thread [Next in Thread>