emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] Include heading title in HTML section-number cross-reference, li


From: D. C. Toedt
Subject: Re: [O] Include heading title in HTML section-number cross-reference, like LaTex \nameref?
Date: Sat, 8 Feb 2014 16:46:02 -0600

That works -- please email me privately with where to send the $100 via PayPal.  Thanks!

(Org-mode maintainer [Bastien, still?], can you please let me know if / when this gets implemented in an official release.)

Regards,

D. C.


D
. C. Toedt III 
 (my
 last name is pronounced "Tate"
Attorney and neutral arbitrator -- tech contracts and intellectual property

address@hidden     LinkedIn: dctoedt    Calendar (redacted)
O: +1 (713) 364-6545    C: +1 (713) 516-8968
    
Houston, Texas (Central time zone)
Common Draft annotated collection of contract clauses

Unless expressly stated otherwise, this message is not intended 
to serve as an electronic signature nor as assent to an agreement.




On Sat, Feb 8, 2014 at 3:50 PM, Nicolas Goaziou <address@hidden> wrote:
Hello,

"D. C. Toedt" <address@hidden> writes:

> QUESTION:  When org-mode headings are NUMBERED, and the file is exported to
> HTML, is there any way to have org-mode include the TITLE, not just the
> section number, of a cross-referenced section, along the lines of the LaTex
> \nameref{} function?  Here's an example:
>
> ==BEGIN EXAMPLE==
>
> #+OPTIONS: H:7 TOC:nil @:t num:1 email:t author:t
>
> * Introduction to Technology Contracts
>   :PROPERTIES:
>   :CUSTOM_ID: IntroTechContracts
>   :END:
>
> Lorem ipsum etc. etc.
>
> * Dangerous Clauses
>   :PROPERTIES:
>   :CUSTOM_ID: DangerousClauses
>   :END:
>
> Lorem ipsum etc. etc. -- see Section [[#IntroTechContracts]].
>
> ==END EXAMPLE==

[...]

> Is that currently doable?

I think so. Not trivial, but doable nonetheless.

--8<---------------cut here---------------start------------->8---
#+MACRO: get-title (eval (save-excursion (org-open-link-from-string "[[#$1]]") (org-get-heading nil nil)))
#+MACRO: SECREF [[#$1][{{{get-title($1)}}}]]
#+OPTIONS: H:7 toc:nil num:1 email:t author:t

* Introduction to Technology Contracts
  :PROPERTIES:
  :CUSTOM_ID: IntroTechContracts
  :END:

Lorem ipsum etc. etc.

* Dangerous Clauses
  :PROPERTIES:
  :CUSTOM_ID: DangerousClauses
  :END:

Lorem ipsum etc. etc. -- see Section {{{SECREF(IntroTechContracts)}}}
--8<---------------cut here---------------end--------------->8---


Regards,

--
Nicolas Goaziou


reply via email to

[Prev in Thread] Current Thread [Next in Thread]