1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
|
<xsl:key name="regrouper" match="id" use="."/>
...
<xsl:apply-templates select="racine/observations/observation/code/id[generate-id(.)=generate-id(key('regrouper',.)[1])]"/>
<xsl:template match="id">
<xsl:variable name="newcode">
<xsl:value-of select="concat(. , '.', ../libelle/caracteristiques/caracteristique[1], ../libelle/caracteristiques/caracteristique[2])"/>
</xsl:variable>
<tr>
<td><xsl:value-of select="$newcode"/></td>
<td align="center"><xsl:value-of select="document('../XML/toto.xml')/root/code[@id=$newcode]/@libelle"/></td>
<td><xsl:value-of select="count(document('../XML/toto.xml')/root/code[@id=$newcode])"/></td>
</tr>
</xsl:template> |
Partager