Subject: Re: [xsl] Generating an index of terms in a TEI P5 book MS From: "Charles Muller acmuller@xxxxxxxxxxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> Date: Sun, 12 Jun 2016 12:42:52 -0000 |
On 12.06.2016 14:33, Charles Muller acmuller@xxxxxxxxxxxxxxx wrote:
I wonder if there is a way to eliminate the doubled entries with XSLT?
As you seem to have access to XSLT 2.0, you could simply use
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xpath-default-namespace="http://www.tei-c.org/ns/1.0" version="2.0"> <xsl:template match="TEI"> <html> <head/> <body> <xsl:for-each select="distinct-values(//term[@xml:lang='zh'])"> <xsl:sort select="."/> <p><xsl:value-of select="."/><xsl:text> </xsl:text></p> </xsl:for-each> </body> </html> </xsl:template> </xsl:stylesheet>
--------------------------- A. Charles Muller
Graduate School of Humanities and Sociology Faculty of Letters University of Tokyo 7-3-1 HongE , BunkyE -ku Tokyo 113-8654, Japan
Web Site: Resources for East Asian Language and Thought http://www.acmuller.net
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Generating an index of te, Martin Honnen martin | Thread | Re: [xsl] Generating an index of te, Wendell Piez wapiez@ |
Re: [xsl] Generating an index of te, Martin Honnen martin | Date | Re: [xsl] is there a way to hash an, Graydon graydon@xxxx |
Month |