Subject: Re: Transform to html
From: "Agnes kielen" <a.kielen@xxxxxxx>
Date: Sat, 26 Jan 2002 12:24:36 +0100
|
Hello Alvaro,
The following stylesheet should help you in the good direction
<?xml version="1.0"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="element">
<xsl:value-of select="position()"/>. <xsl:value-of select="."/>
</xsl:template>
</xsl:stylesheet>
The positon() function counts the number of times the template is called.
Greetings,
Agnes
----- Original Message -----
From: "Alvaro Mujica" <amujicaj@xxxxxxxxxx>
To: <xsl-list@xxxxxxxxxxxxxxxxxxxxxx>
Sent: Saturday, January 26, 2002 9:04 AM
Subject: Transform to html
> Hi,
> I'm kind of new with xslt and I'm stuck with a very simple problem. I
> have the xml document below and I¹m transforming it to a html document:
> <text>
> It is divided in three:
> <list>
> <element>
> A
> </element>
> <element>
> B
> </element>
> <element>
> C
> </element>
> </list>
> The first...
> </text>
>
> I want to be able to show it like this:
>
> It is divided in three:
> 1. A
> 2. B
> 3. C
> The first...
>
> Thank you in advance.
> Alvaro
>
>
> XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
>
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|