[xsl] Numbering

Subject: [xsl] Numbering
From: kobily <kobily@xxxxxxxxxxxx>
Date: Wed, 10 Oct 2001 19:13:31 +0200
Hi !!!

I have to create a list of options:
<option value="1">Some
<option value="2">some-elem
<option value="3">other elem

This should be only for the elements that have content (tgis have been solved), my problem is to give the number of each elem. I can´t increase a variable.
I´m using:

<xsl:variable name="values">0</xsl:variable>
<xsl:for-each select="elem">
<option><xsl:attribute name="value"><xsl:value-of select="$values + 1"/></xsl:attribute><xsl:value-of select="elem"/></option>

But the variable "values" is always 1.


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

Current Thread