XSLT provides several ways for you to number portions of your output, for example in a numbered list of items. This section illustrates numbering in XSLT. We will use a two-player, two-hand card game as an example, which consists of an XML file, cardgame.xml, and an XSLT style sheet that displays the card game as an HTML document.
This section contains the following topics.
position Function | <xsl:number> Element | <xsl:decimal-format> Element | format-number Function | Context and Navigation in XPath