summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Guerry <bzg@altern.org>2011-02-16 11:53:28 +0100
committerBastien Guerry <bzg@altern.org>2011-02-16 11:53:28 +0100
commitc7700d7bbee4f7596feb199b1ec1bc7750d4fb48 (patch)
treea9350a9550d4c4d0b0c5e45b90377bf22c92cefd
parent045214f9d2938f1cb3ef5b1c9f49a2c0d334d26b (diff)
downloadorg-mode-c7700d7bbee4f7596feb199b1ec1bc7750d4fb48.tar.gz
* org-html.el (org-export-as-html): expand the HTML title.
This fix is a modified version of a patch submitted by Pierre Téchoueyres.
-rw-r--r--lisp/org-html.el23
1 files changed, 12 insertions, 11 deletions
diff --git a/lisp/org-html.el b/lisp/org-html.el
index 9135c73..23e1316 100644
--- a/lisp/org-html.el
+++ b/lisp/org-html.el
@@ -1092,16 +1092,17 @@ PUB-DIR is set, use this as the publishing directory."
(date (plist-get opt-plist :date))
(author (plist-get opt-plist :author))
(html-validation-link (or org-export-html-validation-link ""))
- (title (or (and subtree-p (org-export-get-title-from-subtree))
- (plist-get opt-plist :title)
- (and (not body-only)
- (not
- (plist-get opt-plist :skip-before-1st-heading))
- (org-export-grab-title-from-buffer))
- (and buffer-file-name
- (file-name-sans-extension
- (file-name-nondirectory buffer-file-name)))
- "UNTITLED"))
+ (title (org-html-expand
+ (or (and subtree-p (org-export-get-title-from-subtree))
+ (plist-get opt-plist :title)
+ (and (not body-only)
+ (not
+ (plist-get opt-plist :skip-before-1st-heading))
+ (org-export-grab-title-from-buffer))
+ (and buffer-file-name
+ (file-name-sans-extension
+ (file-name-nondirectory buffer-file-name)))
+ "UNTITLED")))
(link-up (and (plist-get opt-plist :link-up)
(string-match "\\S-" (plist-get opt-plist :link-up))
(plist-get opt-plist :link-up)))
@@ -1280,7 +1281,7 @@ lang=\"%s\" xml:lang=\"%s\">
org-export-html-preamble-format))
(cadr (assoc "en" org-export-html-preamble-format))))))
(insert (format-spec html-preamble-format
- `((?t . ,(org-html-expand title))
+ `((?t . ,title)
(?a . ,author) (?d . ,date) (?e . ,email)))))))
(if (and org-export-with-toc (not body-only))