[xsl] adding numbers

Subject: [xsl] adding numbers
From: 04083259@xxxxxxxxxxxxx
Date: Wed, 30 Mar 2005 13:36:43 +0100 (BST)
i have the following xml database

<sub1> <x>5</x><y>312</y></sub1>
<sub2><x>40</x><y> 48</y><x>120</x><y>-32</y><x>160</x><y>-6</y></sub2>

the following template will add the value of x and y  in last position
within the element sub2 to   x and y  in sub3

the problem i need to add  to x and y  within the element sub3 all the
priviouse x(s) and y(s) in last position  of the elements  sub2 and sub1
sub0 but could be more then these 3 elements

 <xsl:template match="path">
   <xsl:for-each select="*" >

<xsl:when test="contains(name(.), 'sub3') " >



Current Thread