This is the mail archive of the
docbook-apps@lists.oasis-open.org
mailing list .
HTMLHelp, base dir missing from filepaths in alias.h
- From: Rob Smith <rob dot smith at ifrsys dot com>
- To: docbook-apps at lists dot oasis-open dot org
- Date: Thu, 24 Jan 2002 11:13:16 +0000
- Subject: DOCBOOK-APPS: HTMLHelp, base dir missing from filepaths in alias.h
- Reply-to: rob dot smith at ifrsys dot com
Hi,
There seems to be a bug in the htmlhelp.xsl template that generates the
alias.h file. I have set params to create the topic files in a subdirectory:
<xsl:param name="base.dir" select="'html/'"/>
<xsl:param name="use.id.as.filename" select="1"/>
but the entries in alias.h do not include the base directory, so I get:
IDH_ERR_COPYFILE=IDH_ERR_COPYFILE.html
which should be:
IDH_ERR_COPYFILE=html/IDH_ERR_COPYFILE.html
I fixed the problem by overriding the template as follows in my driver
stylesheet, to include the value of the $base.dir variable in the output:
<xsl:template match="processing-instruction('dbhh')" mode="hh-alias">
<xsl:variable name="topicname">
<xsl:call-template name="pi-attribute">
<xsl:with-param name="pis" select="."/>
<xsl:with-param name="attribute" select="'topicname'"/>
</xsl:call-template>
</xsl:variable>
<xsl:value-of select="$topicname"/>
<xsl:text>=</xsl:text>
<xsl:value-of select="$base.dir"/> <!-- LINE INSERTED -->
<xsl:call-template name="href.target">
<xsl:with-param name="object" select=".."/>
</xsl:call-template>
<xsl:text>
</xsl:text>
</xsl:template>
It all works beautifully now. Should this change be made to htmlhelp.xsl in
the docbook distribution?
Regards,
Rob Smith