<xsl:template name="html.head">
<xsl:param name="prev" select="/foo"/>
<xsl:param name="next" select="/foo"/>
+ <xsl:variable name="this" select="."/>
<xsl:variable name="home" select="/*[1]"/>
<xsl:variable name="up" select="parent::*"/>
</xsl:attribute>
</link>
</xsl:if>
+
+ <xsl:if test="$html.extra.head.links != 0">
+ <xsl:for-each select="//part
+ |//reference
+ |//chapter
+ |//article
+ |//refentry
+ |//appendix[not(parent::article)]|appendix
+ |//glossary[not(parent::article)]|glossary
+ |//index[not(parent::article)]|index">
+ <link rel="{local-name(.)}">
+ <xsl:attribute name="href">
+ <xsl:call-template name="href.target">
+ <xsl:with-param name="object" select="."/>
+ </xsl:call-template>
+ </xsl:attribute>
+ <xsl:attribute name="title">
+ <xsl:apply-templates select="." mode="object.title.markup.textonly"/>
+ </xsl:attribute>
+ </link>
+ </xsl:for-each>
+
+ <xsl:for-each select="section|sect1|refsection|refsect1">
+ <link>
+ <xsl:attribute name="rel">
+ <xsl:choose>
+ <xsl:when test="local-name($this) = 'section'
+ or local-name($this) = 'refsection'">
+ <xsl:value-of select="'subsection'"/>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:value-of select="'section'"/>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:attribute>
+ <xsl:attribute name="href">
+ <xsl:call-template name="href.target">
+ <xsl:with-param name="object" select="."/>
+ </xsl:call-template>
+ </xsl:attribute>
+ <xsl:attribute name="title">
+ <xsl:apply-templates select="." mode="object.title.markup.textonly"/>
+ </xsl:attribute>
+ </link>
+ </xsl:for-each>
+
+ <xsl:for-each select="sect2|sect3|sect4|sect5|refsect2|refsect3">
+ <link rel="subsection">
+ <xsl:attribute name="href">
+ <xsl:call-template name="href.target">
+ <xsl:with-param name="object" select="."/>
+ </xsl:call-template>
+ </xsl:attribute>
+ <xsl:attribute name="title">
+ <xsl:apply-templates select="." mode="object.title.markup.textonly"/>
+ </xsl:attribute>
+ </link>
+ </xsl:for-each>
+ </xsl:if>
</head>
</xsl:template>
<!ENTITY html.base SYSTEM "../params/html.base.xml">
<!ENTITY html.cleanup SYSTEM "../params/html.cleanup.xml">
<!ENTITY html.ext SYSTEM "../params/html.ext.xml">
+<!ENTITY html.extra.head.links SYSTEM "../params/html.extra.head.links.xml">
<!ENTITY html.longdesc SYSTEM "../params/html.longdesc.xml">
<!ENTITY html.longdesc.link SYSTEM "../params/html.longdesc.link.xml">
<!ENTITY html.stylesheet SYSTEM "../params/html.stylesheet.xml">
<reference><title>Chunking</title>
&html.ext;
+&html.extra.head.links;
&root.filename;
&base.dir;
&generate.manifest;
<src:fragref linkend="html.base.frag"/>
<src:fragref linkend="html.cleanup.frag"/>
<src:fragref linkend="html.ext.frag"/>
+<src:fragref linkend="html.extra.head.links.frag"/>
<src:fragref linkend="html.longdesc.frag"/>
<src:fragref linkend="html.longdesc.link.frag"/>
<src:fragref linkend="html.stylesheet.frag"/>
--- /dev/null
+<refentry id="html.extra.head.links">
+<refmeta>
+<refentrytitle>html.extra.head.links</refentrytitle>
+<refmiscinfo role="type">boolean</refmiscinfo>
+</refmeta>
+<refnamediv>
+<refname>html.extra.head.links</refname>
+<refpurpose>Toggle extra HTML head link information</refpurpose>
+</refnamediv>
+
+<refsynopsisdiv>
+<src:fragment id='html.extra.head.links.frag'>
+<xsl:param name="html.extra.head.links" select="1"/>
+</src:fragment>
+</refsynopsisdiv>
+
+<refsect1><title>Description</title>
+
+<para>If non-zero, extra <sgmltag>link</sgmltag> elements will be
+generated in the <sgmltag>head</sgmltag> of chunked HTML files. These
+extra links point to chapters, appendixes, sections, etc. as supported
+by the <quote>Site Navigation Bar</quote> in Mozilla 1.0 (as of CR1, at least).
+</para>
+
+</refsect1>
+</refentry>