I cannot get the choice to work: it does not copy either <Item> and if I
negate the test
<xsl:when test=" not(preceding-sibling::Item[1] eq .)"/>
it copies both. What am I doing wrong in the test?
Thanks,
Mark
<List>
<Item>
<Heading entry="subject" data="Aleš, Mikoláš. 1852-1913">
<ToRef xref="see" data="Artists - Aleš, Mikoláš. 1852-1913" file="a"
block="A55-2"/>
</Heading>
</Item>
<Item>
<Heading entry="subject" data="Aleš, Mikoláš. 1852-1913">
<ToRef xref="see" data="Artists - Aleš, Mikoláš. 1852-1913" file="a"
block="A55-2"/>
</Heading>
</Item>
<List>
<xsl:template match="Item">
<xsl:if test="descendant::ToRef">
<xsl:choose>
<xsl:when test=" preceding-sibling::Item[1] eq ."/> <!-- Ignore the
second (and further) identical sequential Items -->
<xsl:otherwise>
<xsl:copy-of select="."/>
</xsl:otherwise>
</xsl:choose>
</xsl:if>
..... <!-- lots of other transformations going on -->
</xsl:template>
--~------------------------------------------------------------------
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>
--~--