[XSL-LIST Mailing List Archive Home]
[By Thread]
[By Date]
Re: [xsl] traversing node by node in apply-templates
Subject: Re: [xsl] traversing node by node in apply-templates From: ARULRAJ <p_arulraj@xxxxxxxxx> Date: Wed, 10 Dec 2003 22:06:21 -0800 (PST) |
Hello all, I have doubt using apply-templates. I am using XML, XSLT for generating html. I have given sample code here. ------------------------------------------------- XML files here <label> <binding variable="iIndex" value="2"/> <rule> <condition> <conditionsuccess> <binding variable="TrueIndex" value="3"/> </conditionsuccess> </condition> <bindings> <binding variable="aftercondition1" value="1"/> <binding variable="aftercondition2" value="2"/> <binding variable="aftercondition3" value="3"/> </bindings> </rule> </label> -------------------------------------------------- I want to traverse content of <rule> one by one. Here <bindings> and <condition> are appear in XML any order. So, If I use the below code only <bindings> will be processed and <condition> next. How to traverse one by one <xsl:template match="rule"> <xsl:if test="bindings"> <xsl:apply-templates select="bindings"/> </xsl:if> <xsl:if test="condition"> <xsl:apply-templates select="condition"/> </xsl:if> </xsl:template> Please give your suggestion. Thanks Regards, Arul __________________________________ Do you Yahoo!? New Yahoo! Photos - easier uploading and sharing. http://photos.yahoo.com/ XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] sorting in <xsl:apply-tem, Mukul Gandhi | Thread | Re: [xsl] traversing node by node i, J.Pietschmann |
[xsl] Re: Re: Unbounded element gro, Dimitre Novatchev | Date | Re: [xsl] group elements, Mukul Gandhi |
Month |