Re: [xsl] "grouping" footnote numbers

Subject: Re: [xsl] "grouping" footnote numbers
From: Wendell Piez <wapiez@xxxxxxxxxxxxxxxx>
Date: Mon, 17 Oct 2011 15:41:51 -0400

Being away for a week I missed the fun thread about footnote reference numbering.

(I don't want to think about the fact that I think this is fun, assuming only that on this list I'm in good company.)

In any case, I have only one small thing to add:

On 10/11/2011 9:33 AM, was written:

In XSLT 2.0:

xref[. is key('fn',@href)[1]]


So that's what I've got now:

<xsl:key name="fn" match="xref" use="@href"/>
<xsl:template match="xref">
   <a href="{@href}">
       <xsl:for-each-group select="key('fn', @href)" group-by="@href">
         <xsl:number level="any" count="xref[count(.|key('fn',@href)[1])=1]"/>

I hope my users will be impressed (but since they view most of what we do as magic anyway, they probably won't be). Thank you all for your help.

-- ====================================================================== Wendell Piez mailto:wapiez@xxxxxxxxxxxxxxxx Mulberry Technologies, Inc. 17 West Jefferson Street Direct Phone: 301/315-9635 Suite 207 Phone: 301/315-9631 Rockville, MD 20850 Fax: 301/315-8285 ---------------------------------------------------------------------- Mulberry Technologies: A Consultancy Specializing in SGML and XML ======================================================================

Current Thread