From: Bernt Hansen <bernt@norang.ca>
To: pquintana@obsebre.es
Cc: emacs-orgmode@gnu.org
Subject: Re: Use id property as anchor in the Table of Contents
Date: Wed, 07 Sep 2011 20:34:54 -0400 [thread overview]
Message-ID: <87zkifx45t.fsf@norang.ca> (raw)
In-Reply-To: <CABnQcBL7LaHz_qxFiEXhW95KDUm6pwavad=1HccJRNNwxa5P=w@mail.gmail.com> ("Pere Quintana Seguí"'s message of "Wed, 7 Sep 2011 23:07:46 +0200")
Pere Quintana Seguí <pquintana@obsebre.es> writes:
> Hi,
>
> I'm using Org-mode to publish my website. One of my site's pages has
> a lot of sections and the number of sections is increasing rapidly.
>
> My problem is that the HTML exporter, in the Table of Contents, is
> using the section numbers as anchors. As the section numbers change
> with time, I can't get stable links across versions of the document.
>
> As many of the sections (headings) have id properties, I'd like the
> HTML exporter to use them as anchor for the Table of Contents, when
> available.
>
> Is this possible? I didn't find an answer in the manual.
>
> As an example. This is the document I'm working on:
> http://pere.quintanasegui.com/diccionari-tecnologia.html#sec-2-78
>
> As you can see, section 2.78, called RSS, has the anchor sec-2-78. If
> the anchor was its id "04E3903E-EAF1-499F-98CD-9E3E4BA0806A", the
> link would remain the same in the future. I don't mind if the URL is
> not human readable. Sec-2-78 isn't human readable too.
Hi Pere,
You can manually provide CUSTOM_ID properties. These ids are used in
the TOC.
e.g.
* Reminders
:PROPERTIES:
:CUSTOM_ID: Reminders
:END:
for
http://doc.norang.ca/org-mode.html#Reminders
I don't know if there is a way to use the ID property automatically.
Regards,
Bernt
next prev parent reply other threads:[~2011-09-08 0:35 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-09-07 21:07 Use id property as anchor in the Table of Contents Pere Quintana Seguí
2011-09-08 0:34 ` Bernt Hansen [this message]
2011-09-08 10:53 ` Pere Quintana Seguí
2011-09-13 10:05 ` Olaf Dietsche
2011-09-13 14:53 ` Pere Quintana Seguí
2011-09-15 9:18 ` Olaf Dietsche
2011-09-15 11:52 ` Pere Quintana Seguí
2012-04-20 11:51 ` Bastien
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87zkifx45t.fsf@norang.ca \
--to=bernt@norang.ca \
--cc=emacs-orgmode@gnu.org \
--cc=pquintana@obsebre.es \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).