[O] footnotes position in html export

2015-11-08 Thread Orm Finnendahl
Hi,

 when exporting an org-file to html using org-mode.js, the footnotes
appear at the end of the document.

I'd rather have the footnotes at the end of each section. As far as I
understand, this can be achieved by distributung the different
sections to different .org documents and including those from a master
document.

Unfortunately in my document are many sections which are rather short
and I'd prefer to keep them in a single document. Does anybody know of
a way to achieve this? I couldn't find anything related to that on the
web.

--
Orm



Re: [O] footnotes position in html export

2015-11-08 Thread Orm Finnendahl
Hi Nicolas,

 thanks a lot, that sounds quite feasible and your suggestions will
probably save me a lot of time! I just started writing the book and
first need some more content but will look into coding it while it's
growing.

I'll post back to the list when I have results in case someone is
interested and has a use for it.

--
Orm

Am Sonntag, den 08. November 2015 um 16:11:03 Uhr (+0100) schrieb Nicolas 
Goaziou:
> Hello,
> 
> Orm Finnendahl  writes:
> 
> > ok, thanks. I'll look into it. Maybe it's not too hard to
> > implement.
> 
> It shouldn't. Basically, you need to:
> 
>   1. Add an optional argument to `org-html-footnote-section' specifying
>  the scope of footnotes, skip
>  `org-export-collect-footnote-definitions' altogether and use
>  `org-element-map' to find "first footnotes references" (see
>  `org-export-footnote-first-reference-p') in the scope.
> 
>  Then with `org-export-get-footnote-definition', you can build the
>  footnote section.
> 
>   2. Call `org-html-footnote-section' from `org-html-section', with the
> parent headline, if any, or the current section otherwise as the
> current scope.
> 
>   3. Create a new variable to toggle behaviour of footnotes.
> 
> HTH,
> 
> Regards,
> 
> -- 
> Nicolas Goaziou



Re: [O] footnotes position in html export

2015-11-08 Thread Rasmus
Hi Orm,

Orm Finnendahl  writes:

>  when exporting an org-file to html using org-mode.js, the footnotes
> appear at the end of the document.

I don't think we maintain an org-mode.js.  Are you talking about Mooz's
org-js project?  Or ox-html.el?

> I'd rather have the footnotes at the end of each section. As far as I
> understand, this can be achieved by distributung the different
> sections to different .org documents and including those from a master
> document.

I guess so, but only if exported to different documents.  #+include merges
the documents before starting the transcoding.

> Unfortunately in my document are many sections which are rather short
> and I'd prefer to keep them in a single document. Does anybody know of
> a way to achieve this? I couldn't find anything related to that on the
> web.

I think this is not possible.  See org-html-inner-template.

Greetings from Nordend,
Rasmus

-- 
⠠⠵




Re: [O] footnotes position in html export

2015-11-08 Thread Rasmus
Hi,

Orm Finnendahl  writes:

> Am Sonntag, den 08. November 2015 um 12:10:59 Uhr (+0100) schrieb Rasmus:
>> 
>> I don't think we maintain an org-mode.js.  Are you talking about Mooz's
>> org-js project?  Or ox-html.el?
>
> sorry, I meant "org-info.js"

OK.  I haven't used it for years.  Skimming ox-html, no code in  is
changed based on info.js.

>> I think this is not possible.  See org-html-inner-template.
>> 
>
> ok, thanks. I'll look into it. Maybe it's not too hard to
> implement. The org manual has footnotes on every page if it is
> exported into different documents. Is there any information somewhere
> about how the org manual html pages were generated? I couldn't
> find the sources of the manual. Are they available somewhere?

The manual is generated via texinfo.  You can check doc/Makefile

I guess the difference between

http://orgmode.org/org.html

and

http://orgmode.org/manual/

is whether the --no-split was issued to texinfo.

The Magit-2 manual is generated from Org via ox-texinfo.el.

>> Greetings from Nordend,
>
> I'm also in Nordend, but that's a part of Frankfurt, Germany ;-)

That was the intended reference.

Rasmus

-- 
Hvor meget poesi tror De kommer ud af et glas isvand?




Re: [O] footnotes position in html export

2015-11-08 Thread Nicolas Goaziou
Hello,

Orm Finnendahl  writes:

> ok, thanks. I'll look into it. Maybe it's not too hard to
> implement.

It shouldn't. Basically, you need to:

  1. Add an optional argument to `org-html-footnote-section' specifying
 the scope of footnotes, skip
 `org-export-collect-footnote-definitions' altogether and use
 `org-element-map' to find "first footnotes references" (see
 `org-export-footnote-first-reference-p') in the scope.

 Then with `org-export-get-footnote-definition', you can build the
 footnote section.

  2. Call `org-html-footnote-section' from `org-html-section', with the
parent headline, if any, or the current section otherwise as the
current scope.

  3. Create a new variable to toggle behaviour of footnotes.

HTH,

Regards,

-- 
Nicolas Goaziou



Re: [O] footnotes position in html export

2015-11-08 Thread Orm Finnendahl
Am Sonntag, den 08. November 2015 um 12:10:59 Uhr (+0100) schrieb Rasmus:
> 
> I don't think we maintain an org-mode.js.  Are you talking about Mooz's
> org-js project?  Or ox-html.el?

sorry, I meant "org-info.js"

> 
> I think this is not possible.  See org-html-inner-template.
> 

ok, thanks. I'll look into it. Maybe it's not too hard to
implement. The org manual has footnotes on every page if it is
exported into different documents. Is there any information somewhere
about how the org manual html pages were generated? I couldn't
find the sources of the manual. Are they available somewhere?

> Greetings from Nordend,

I'm also in Nordend, but that's a part of Frankfurt, Germany ;-)

Orm