xml editor

Supported platforms

Compatible with Windows7 & Mac OS X Snow Leopard

Ready for data server software
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

RE: [xsl] avoiding repeated items


Subject: RE: [xsl] avoiding repeated items
From: "Evan Lenz" <elenz@xxxxxxxxxxx>
Date: Thu, 1 Mar 2001 15:01:59 -0800

Tim Watts wrote:
> <xsl:for-each select="poetas/autor">
> 	<xsl:choose>
> 		<xsl:when test="not(.=preceding::autor)">
> 			<xsl:value-of select="."/>
> 		</xsl:when>
> 	</xsl:choose>
> </xsl:for-each>

Yep, or more succinctly, and with line breaks:

<xsl:for-each select="/poetas/autor[not(.=preceding::autor)]">
  <xsl:value-of select="."/>
<xsl:text>
</xsl:text>
</xsl:for-each>

Evan

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



Current Thread
XML Editor | XML Author | WYSIWYG Editors | Schema Editor | XSD Documentation | XSL/XSLT Editor | XQuery | XML Databases | SVN Client
© 2002-2011 SyncRO Soft Ltd. All rights reserved. | Sitemap | Privacy Policy | This website was created & generated with <oXygen/>®XML Editor