我想要合并相同的元素,例如:
<Root>
<row>
<WID>10</WID>
<word>Bob</word>
<SID>2</SID>
<Ah>1</Ah>
</row>
<row>
<WID>5941</WID>
<word>Jany</word>
<SID>2</SID>
<Ah>1</Ah>
</row>
</Root>
结果是:
<span>Bob Jany</span>
我写了这个,但它是错误的:
<xsl:choose>
<xsl:when test = "Ah[text()]=Ah[text()]">
<span>
<xsl:value-of select="./word"/>
</span>
</xsl:when>
</xsl:choose>