emacs-orgmode
[Top][All Lists]
Advanced

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

[O] [PATCH] export to various flavors of (X)HTML


From: Eric Abrahamsen
Subject: [O] [PATCH] export to various flavors of (X)HTML
Date: Fri, 19 Apr 2013 17:57:46 +0800
User-agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3 (gnu/linux)

I'm starting a new thread for this since the previous discussion was
buried in with something tangential.

I've attached what I think is a working patch to allow ox-html to export
to different flavors of (X)HTML. It works via `org-html-doctype': in
addition to setting it to a doctype string directly, you can also set it
to one of the following (defaults to xhtml-strict):

html4-strict
html4-transitional
html4-frameset
xhtml-strict
xhtml-transitional
xhtml-framset
xhtml-11
html5

The doctype will be set correctly, and the HTML output will be adjusted
to conform to the requirements of that doctype, with No Errors
Whatsoever™. The results validate, anyway...

I'm not proud of some of the implementation (self-closing vs
non-self-closing tags are ugly, and I wish org-html-html5-p and
org-html-xhtml-p were variables, not functions), but there it is, it
seems to work.

If this is deemed okay I'll send a version of the patch with a proper
commit message, and also updated documentation.

And once that's done I've got another that builds on this, allowing you
to use stuff like <canvas> and <video>. Whee!

Eric

Attachment: 0001-Export-to-different-flavors-of-x-html.patch
Description: Text Data


reply via email to

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