emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* org-html-publish-to-html: embed HTML in first line of export
@ 2013-12-04 19:30 Jürgen Hötzel
  2013-12-04 22:23 ` Nicolas Goaziou
  0 siblings, 1 reply; 4+ messages in thread
From: Jürgen Hötzel @ 2013-12-04 19:30 UTC (permalink / raw)
  To: emacs-orgmode

Hi,

I use a Org/Jekyll setup: http://orgmode.org/worg/org-tutorials/org-jekyll.html

As described in the tutorial, each Org file must start with the following lines:

#+BEGIN_HTML
---
layout: default
title: Org Test
excerpt: Excerpt from Org
---
#+END_HTML


because Jekyll needs the meta information on top of a HTML file for
processing the pages.


As of the release of Org 8.0 (with the new export framework) the order
of the table of contents and the HTML environment (i inserted on top
of the Org file) has changed. With the new exporter I get this:

<div id="table-of-contents">
<h2>Table of Contents</h2>
<div id="text-table-of-contents">
<ul>
<li><a href="#sec-1">1. Section</a></li>
</ul>
</div>
</div>
---
layout: default
title: Org Test
excerpt: Excerpt from Org
---


wheres with the old exporter i got:

---
layout: default
title: Org Test
excerpt: Excerpt from Org
---

<div id="table-of-contents">
<h2>Table of Contents</h2>
<div id="text-table-of-contents">
<ul>
<li><a href="#sec-1">1. Section</a></li>
</ul>
</div>
</div>


So Jekyll can't process files and the resulted HTML pages are corrupted

Any hints, how i can change the order of the TOC and HTML environment?

Thank!

Jürgen

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: org-html-publish-to-html: embed HTML in first line of export
  2013-12-04 19:30 org-html-publish-to-html: embed HTML in first line of export Jürgen Hötzel
@ 2013-12-04 22:23 ` Nicolas Goaziou
  2013-12-05  2:59   ` Nick Dokos
  2013-12-05  8:46   ` Jürgen Hötzel
  0 siblings, 2 replies; 4+ messages in thread
From: Nicolas Goaziou @ 2013-12-04 22:23 UTC (permalink / raw)
  To: Jürgen Hötzel; +Cc: emacs-orgmode

Hello,

Jürgen Hötzel <juergen@hoetzel.info> writes:

> So Jekyll can't process files and the resulted HTML pages are corrupted
>
> Any hints, how i can change the order of the TOC and HTML environment?

  1. Disable default TOC with, e.g. #+options: toc:nil
  2. Insert your HTML environment
  3. Insert TOC after it with "#+TOC: headlines".


Regards,

-- 
Nicolas Goaziou

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: org-html-publish-to-html: embed HTML in first line of export
  2013-12-04 22:23 ` Nicolas Goaziou
@ 2013-12-05  2:59   ` Nick Dokos
  2013-12-05  8:46   ` Jürgen Hötzel
  1 sibling, 0 replies; 4+ messages in thread
From: Nick Dokos @ 2013-12-05  2:59 UTC (permalink / raw)
  To: emacs-orgmode

Nicolas Goaziou <n.goaziou@gmail.com> writes:

> Hello,
>
> Jürgen Hötzel <juergen@hoetzel.info> writes:
>
>> So Jekyll can't process files and the resulted HTML pages are corrupted
>>
>> Any hints, how i can change the order of the TOC and HTML environment?
>
>   1. Disable default TOC with, e.g. #+options: toc:nil
>   2. Insert your HTML environment
>   3. Insert TOC after it with "#+TOC: headlines".
>
>

The OP talks about changing the order of the TOC and the YAML
front-matter but according to the Jekyll docs [fn:1], this is not
enough:

,----
| Front-matter
| 
| The front-matter is where Jekyll starts to get really cool. Any file
| that contains a YAML front matter block will be processed by Jekyll as a
| special file. The front matter must be the first thing in the file and
| must take the form of valid YAML set between triple-dashed lines. Here
| is a basic example:
| 
| ---
| layout: post
| title: Blogging Like a Hacker
| ---
`----

Footnotes:

[fn:1] http://jekyllrb.com/docs/frontmatter/

-- 
Nick

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: org-html-publish-to-html: embed HTML in first line of export
  2013-12-04 22:23 ` Nicolas Goaziou
  2013-12-05  2:59   ` Nick Dokos
@ 2013-12-05  8:46   ` Jürgen Hötzel
  1 sibling, 0 replies; 4+ messages in thread
From: Jürgen Hötzel @ 2013-12-05  8:46 UTC (permalink / raw)
  To: Nicolas Goaziou; +Cc: emacs-orgmode

On Wed, Dec 4, 2013 at 11:23 PM, Nicolas Goaziou <n.goaziou@gmail.com> wrote:
> Hello,
>
> Jürgen Hötzel <juergen@hoetzel.info> writes:
>
>> So Jekyll can't process files and the resulted HTML pages are corrupted
>>
>> Any hints, how i can change the order of the TOC and HTML environment?
>
>   1. Disable default TOC with, e.g. #+options: toc:nil
>   2. Insert your HTML environment
>   3. Insert TOC after it with "#+TOC: headlines".

Thanks! This fixed the problem!

Jürgen

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-12-05  8:47 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-12-04 19:30 org-html-publish-to-html: embed HTML in first line of export Jürgen Hötzel
2013-12-04 22:23 ` Nicolas Goaziou
2013-12-05  2:59   ` Nick Dokos
2013-12-05  8:46   ` Jürgen Hötzel

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).