summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPuneeth Chaganti <punchagan@gmail.com>2011-03-18 16:52:05 +0000
committerBastien Guerry <bzg@altern.org>2011-03-23 15:07:07 +0100
commita201b11286d74407614b62b61a5e04446d5d6eea (patch)
tree72b57f448ce4f17f9328751060adaca383b5ebae
parentc10933415212abad1b8adcb87c93b4b254cd86d0 (diff)
downloadorg-mode-a201b11286d74407614b62b61a5e04446d5d6eea.tar.gz
Fix HTML export of footnotes with lists, tables, quotes, etc.
* org-html.el (org-export-as-html): Fix export of footnotes containing lists, tables, quotes, etc.
-rw-r--r--lisp/org-html.el9
1 files changed, 6 insertions, 3 deletions
diff --git a/lisp/org-html.el b/lisp/org-html.el
index 06305f6..7fd2079 100644
--- a/lisp/org-html.el
+++ b/lisp/org-html.el
@@ -1691,9 +1691,12 @@ lang=\"%s\" xml:lang=\"%s\">
(save-excursion
(goto-char (point-min))
- (while (re-search-forward "<p class=\"footnote\">[^\000]*?\\(</p>\\|\\'\\)" nil t)
- (push (match-string 0) footnotes)
- (replace-match "" t t)))
+ (while (re-search-forward
+ "\\(\\(<p class=\"footnote\">\\)[^\000]*?\\)\\(\\(\\2\\)\\|\\'\\)"
+ nil t)
+ (push (match-string 1) footnotes)
+ (replace-match "\\4" t nil)
+ (goto-char (match-beginning 0))))
(when footnotes
(insert (format org-export-html-footnotes-section
(nth 4 lang-words)