[l2h] mnemonic anchors

Ross Moore ross at ics.mq.edu.au
Fri Jan 2 01:24:32 CET 2004


Hello Jens,

On Tue, 23 Sep 2003, Jens Lehmann wrote:

> Hello,
>
> currently I'm managing a document which is updated frequently. It is
> important that links to certain sections of the document stay valid
> after an update. I managed to get symbolic names for the html files
> (every section is an html file) by using $LONG_TITLES or writing a
> custom_title_hook function (both ways work).
>
> The next problem is that subsections (and below) have anchors which are
> not safe for updates, for instance <A
> NAME="SECTION000420000000000000000">. I would like to have the headings

If the whole document is being updated, so will these names.
So where is the problem ?

Are you recording some of these names as constants, then creating
hyperlinks to them ?   That's not a recommended technique.
Instead you should use LaTeX's symbolic \label--\ref mechanism,
which assigns your own choice of name for anchor targets.

Either syntax should work:
   \subsection{... subsection name ...\label{..label...}}
   \subsection{... subsection name ...}\label{..label...}
creating an anchor that immediately precedes the subsection title,
so that hyperlinks jump to the window location that has the title
at the top.

> of the subsections and subsubsections as anchor names. I'm aware that
> this causes trouble if a heading appears more than once within one html
> file, but this is not a problem in our case. It's important that the
> mnemonic anchors are the ones which are actually used in the document
> (for example in the table of contents). How can this be achieved?

You will have to explain to me why this is necessary, for a single site.
It sounds like you have a complicated site which is not always updated
as a single unit, and want some parts to link into others.

The  labels.pl  file is designed for this.
It gives you perl-coding for the \label commands used within one
document, so that they can be referenced from another.
This is the basis of the  \externalref  mechanism, using
the \externallabels  command.

>
> Jens

Hope this helps,

	Ross Moore


>
> _______________________________________________
> latex2html mailing list
> latex2html at tug.org
> http://tug.org/mailman/listinfo/latex2html
>


More information about the latex2html mailing list