From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Sebastien Vauban" Subject: Re: Org-special-blogs does not make well-formed xhtml Date: Mon, 03 Oct 2011 15:26:19 +0200 Message-ID: <80r52unr44.fsf@somewhere.org> References: <4E89AE38.3020309@christianmoe.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org-mXXj517/zsQ@public.gmane.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org-mXXj517/zsQ@public.gmane.org To: emacs-orgmode-mXXj517/zsQ@public.gmane.org Hi Christian Moe, Christian Moe wrote: > Hi, > > XHTML produced with Org-special-blocks is not well-formed;
tags > get wrapped in

tags. Example: > > Some text. > > #+begin_sidebar > Some details left out of the main text. > > Some more details. > #+end_sidebar > > Some more text. > > This results in the following html, which causes XML processors to fail. > >

>

>

>

> Some more text. >

> > The problem seems to be fixed by un-commenting the fifth line in the > below function in org-special-blocks.el: > > (defun org-special-blocks-convert-html-special-cookies () > "Converts the special cookies into div blocks." > ;; Uses the dynamically-bound variable `line'. > (when (string-match "^ORG-\\(.*\\)-\\(START\\|END\\)$" line) > ; (org-close-par-maybe) > (message "%s" (match-string 1)) > (if (equal (match-string 2 line) "START") > (insert "
\n") > (insert "
\n")) > (throw 'nextline nil))) > > Does anyone know if that was commented out for a reason? git blame suggests it was there since that file org-special-blocks.el has been added (in contrib/lisp, by Carsten, on 2009-05-07 13:53)... Best regards, Seb -- Sebastien Vauban