[l2h] Bug in first hyperlink of TOC

Ulrich Gruenebaum Ulrich Gruenebaum <grueneba@zkom.de>
Wed, 27 Mar 2002 14:34:50 +0100 (MET)


it seems to me that there is a bug in the table of contents (TOC) generated
by LaTeX2HTML. I am using LaTeX2HTML version 2002 (1.62) on FreeBSD,
downloaded from http://www.latex2html.org/~latex2ht/current
as latex2html-2002.tar.gz (20-Mar-2002).

What I mean is that the generated hyperlink of the *first* TOC entry is
missing the anchor part. The anchor is correct in all following TOC
entries. Therefore clicking on the first hyperlink in the TOC brings you to
the top of the document instead of to the start of the section.

For demonstration consider the following LaTeX document "tst.tex":

 \section{First Section}
 \section{Second Section}
 \section{Third Section}

After two runs of latex and then running latex2html with

 latex2html -split 0 tst

the resulting html file "tst/tst.html" contains the following
html code for the TOC:

 <!--Table of Contents-->
 <LI><A NAME="tex2html6" HREF="tst.html">First Section</A>
 <LI><A NAME="tex2html7" HREF="tst.html#SECTION00030000000000000000">Second Section</A>
 <LI><A NAME="tex2html8" HREF="tst.html#SECTION00040000000000000000">Third Section</A>
 <LI><A NAME="tex2html9" HREF="tst.html#SECTION00050000000000000000">About this document ...</A>
 <!--End of Table of Contents-->

Obviously the hyperlink to "First Section" should contain
HREF="tst.html#SECTION00020000000000000000" instead of only HREF="tst.html".

Perhaps there is someone able to fix this?

Best regards

 Ulrich Gruenebaum (grueneba@zkom.de)
 Tel. +49/(0)231/9700-337
 FAX  +49/(0)231/9700-474

 State Diagnostic Systems and Computer Networks
 Joseph-von-Fraunhofer-Str. 20
 D-44227 Dortmund (Germany)