Re: [xsl] Looping a node in XSLT

Subject: Re: [xsl] Looping a node in XSLT
From: Senthilkumaravelan Krishnanatham <senthil@xxxxxxxxx>
Date: Tue, 6 Mar 2007 16:13:29 -0800
I have tried the same and hard time figuring out the syntax.




<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl=" Transform">
<xsl:output method="xml" omit-xml-declaration="no" indent="yes" encoding="UTF-8" />
<xsl:template match="/products">
<xsl:call-template name="COPY">
<xsl:template name="COPY">
<xsl:variable name="n" select="10" />
<xsl:for-each select="1to$n">
<xsl:apply-templates select="//customer/*"/>

On Mar 6, 2007, at 4:02 PM, Abel Braaksma wrote:

Senthilkumaravelan Krishnanatham wrote:
How do I retain the structure of the sibling node?

Please show us first what you tried so far, just out of thin air it is hard guessing.

Inside these "loops" you can use whatever XSLT or XPath you like. Not sure what you mean by "structure", but if you mean "the same structure as you had when you were doing it one loop", just move your current code the location of the loop and you are done.

Current Thread