[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Org-Mode Homepage error
From: |
Achim Gratz |
Subject: |
Re: [O] Org-Mode Homepage error |
Date: |
Tue, 26 Jul 2011 18:00:34 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) |
Bastien <address@hidden> writes:
> I fail to understand why an additional <div id="preamble">
> should break Sebastian's tool.
> </mode lazybum>
For starters, the title now resides in the preamble, but the script
looks for it in content. This error is easily fixed, but I don't know
if it has further repercussions.
--8<---------------cut here---------------start------------->8---
diff --git a/code/org-info-js/org-info-src.js b/code/org-info-js/org-info-src.js
index 2e49e9c..33faaac 100644
--- a/code/org-info-js/org-info-src.js
+++ b/code/org-info-js/org-info-src.js
@@ -522,6 +522,14 @@ var org_html_manager = {
} else { // be backward compatible
t.BODY = document.getElementsByTagName("body")[0];
}}
+ t.PREA = document.getElementById("preamble");
+ t.POST = document.getElementById("postamble");
+ if(null == t.PREA) {
+ t.PREA = t.BODY;
+ }
+ if(null == t.POST) {
+ t.POST = t.BODY;
+ }
if(! t.WINDOW) {
t.WINDOW = document.createElement("div");
t.WINDOW.style.marginBottom = "40px";
@@ -738,7 +746,7 @@ var org_html_manager = {
// Move the title into the first visible section.
// TODO: show title above everything if FIXED_TOC !!!
- t.TITLE = t.BODY.getElementsByTagName("h1")[0];
+ t.TITLE = t.PREA.getElementsByTagName("h1")[0];
if(t.INNER_TITLE && !t.FIXED_TOC && t.VIEW != t.SLIDE_VIEW) {
t.INNER_TITLE = t.TITLE.cloneNode(true);
/* TODO: this is still based on wrong behaviour of browsers (same id for
two elements)
--8<---------------cut here---------------end--------------->8---
Regards,
Achim.
--
+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+
Wavetables for the Terratec KOMPLEXER:
http://Synth.Stromeko.net/Downloads.html#KomplexerWaves
- [O] Org-Mode Homepage error, Renger van Nieuwkoop, 2011/07/25
- Re: [O] Org-Mode Homepage error, Michael Markert, 2011/07/25
- Message not available
- Re: [O] Org-Mode Homepage error, Sebastien Vauban, 2011/07/25
- Re: [O] Org-Mode Homepage error, Nick Dokos, 2011/07/25
- Re: [O] Org-Mode Homepage error, Bastien, 2011/07/25
- Re: [O] Org-Mode Homepage error, Sebastien Vauban, 2011/07/26
- Re: [O] Org-Mode Homepage error, Bastien, 2011/07/26
- Re: [O] Org-Mode Homepage error,
Achim Gratz <=
- Re: [O] Org-Mode Homepage error, Sebastien Vauban, 2011/07/26
- Re: [O] Org-Mode Homepage error, Bastien, 2011/07/27
- Re: [O] Org-Mode Homepage error, Achim Gratz, 2011/07/28
- Re: [O] Org-Mode Homepage error, Achim Gratz, 2011/07/31