Tony Graham wrote:
It may be simpler if you do it all using ">>":
<xsl:template match="r">
<xsl:copy>
<xsl:apply-templates select="*[../g1[1] >> .]"/>
<xsl:for-each-group
select="g1[1] |
*[(. >> ../g1[1]) and (../g2[last()] >> .)] |
g2[last()]"
group-ending-with="g2">
<group>
<xsl:apply-templates select="current-group()"/>
</group>
</xsl:for-each-group>
<xsl:apply-templates select="*[. >> ../g2[last()]]"/>
</xsl:copy>
</xsl:template>
Aha! Very nice. Your other email also presented a very easy to
understand solution. Thanks to both Tony and Abel.
Cheers,
Raman
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--