The footnote marker gets an id of @id, while the
footnote text gets an id of #ftn.@id. They cross link to each other. -->
<xsl:template match="footnote">
- <xsl:variable name="href">
- <xsl:text>#ftn.</xsl:text>
+ <xsl:variable name="name">
<xsl:call-template name="object.id">
<xsl:with-param name="conditional" select="0"/>
</xsl:call-template>
</xsl:variable>
+ <xsl:variable name="href">
+ <xsl:text>#ftn.</xsl:text>
+ <xsl:value-of select="$name"/>
+ </xsl:variable>
<a href="{$href}">
<xsl:apply-templates select="." mode="class.attribute"/>
+ <xsl:if test="$generate.id.attributes = 0">
+ <xsl:attribute name="name">
+ <xsl:value-of select="$name"/>
+ </xsl:attribute>
+ </xsl:if>
+
<sup>
<xsl:apply-templates select="." mode="class.attribute"/>
<xsl:call-template name="id.attribute">
<xsl:with-param name="conditional" select="0"/>
</xsl:call-template>
- <xsl:call-template name="anchor">
- <xsl:with-param name="conditional" select="0"/>
- </xsl:call-template>
<xsl:text>[</xsl:text>
<xsl:apply-templates select="." mode="footnote.number"/>
<xsl:text>]</xsl:text>