ZVON > References > XSLT Reference
Example 79:17: All | XML | >> XSLT << | Output |

XSLT


     <xsl:stylesheet xmlns:xsl = "http://www.w3.org/1999/XSL/Transform" version = "1.0" >
          <xsl:output method = "text" />

          <xsl:template match = "AAA" >
               <xsl:apply-templates select = "BBB" />
          </xsl:template>

          <xsl:template match = "BBB" >
               <xsl:text >
        </xsl:text>
               <xsl:value-of select = "concat('BBB[',position(),'] :')" />
               <xsl:apply-templates />
          </xsl:template>

          <xsl:template match = "text()" >
               <xsl:text > --- </xsl:text>
               <xsl:value-of select = "." />
               <xsl:text > --- </xsl:text>
          </xsl:template>
     </xsl:stylesheet>