Let's assume your document is
<student>
<term>1</term>
<term>2</term>
<term>3</term>
</student>
You need to output <hr/> tag after each "term", except for the last one. To
test this condition, you can use current() and last() functions, which return the current and the last position in a set of nodes defined in "select" clause of your <xsl:for-each> element. So it will be:
<xsl:template match="student">
<xsl:for-each select="term">
<xsl:value-of select="."/>
<xsl:if test="not (current() = last())">
<hr/>
</xsl:if>
</xsl:for-each>
</xsl:template>
the output:
1<hr/>2<hr/>3
[ February 21, 2002: Message edited by: Mapraputa Is ]