This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
count number of <P>s
- From: Dan Cederholm <dan at cederholm dot tv>
- To: xsl-list at lists dot mulberrytech dot com
- Date: Thu, 4 Apr 2002 16:56:20 -0500
- Subject: [xsl] count number of <P>s
- Reply-to: xsl-list at lists dot mulberrytech dot com
Hi,
I'm trying to count the number of <P> tags withing a <![CDATA[ section.
Doing this:
<xsl:value-of select="string-length(.) - string-length(translate(.,
'<P>', ''))"/>
almost gets me there -- but counts each instance of <, P, and >
separately. Is there a way of searching for an *entire* string,
rather than individual characters?
Thanks!
Dan Cederholm
--
dan@cederholm.tv
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list