emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Gitsis Christos <cgitsis@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Bug: customizing HTML export postamble [8.2.7c (8.2.7c-61-g4b9146-elpa @ /home/christos/.emacs.d/elpa/org-20140908/)]
Date: Wed, 8 Oct 2014 21:33:44 +0300	[thread overview]
Message-ID: <CAHDzUL+fNGdzKbmuQoVw_QLGcQXeMLqdLWyeF=W3yewF4Q7h3g@mail.gmail.com> (raw)

Hello,

I was trying to translate the postamble in HTML export in order to
translate it in greek and I faced multiple issues.

1) Setting org-html-postamble to auto generates a postamble different
than setting it to t and leaving org-html-postamble-format to
default. The differences are a) the date string is "Created:" in the
first case and "Date:" in the second, and b) most importantly, in the
second case the Date does not show up at all

2) I added a new language to org-html-postamble-format so that in the
end it looked like

(("el" "<p class=\"author\">Συγγραφέας: %a (%e)</p>
<p class=\"date\">Ημερομηνία: %d</p>
<p class=\"creator\">%c</p>") ("en" "<p class=\"author\">Author: %a (%e)</p>
<p class=\"date\">Date: %d</p>
<p class=\"creator\">%c</p>
<p class=\"validation\">%v</p>"))

I set org-export-default-language to "el" and I got unexpected results.
Strangely, I observed that the postamble of my index.html page was
translated in greek, but
a) the Date was missing (naturally)
b) the author field was different (strangely, it was my linux
username@my hostname, but ok, I guess, since my index.org is
automatically generated and I have no author set for it -- how do I
set it by the way?)
and c) the rest of the pages were in english, and with
org-html-postamble = t ("Date:" + empty date)

------------------------------------------------------------------------

Emacs  : GNU Emacs 24.3.1 (x86_64-pc-linux-gnu, GTK+ Version 3.12.2)
 of 2014-09-12 on gandalf
Package: Org-mode version 8.2.7c (8.2.7c-61-g4b9146-elpa @
/home/christos/.emacs.d/elpa/org-20140908/)

current state:
==============
(setq
 org-tab-first-hook '(org-hide-block-toggle-maybe
org-src-native-tab-command-maybe org-babel-hide-result-toggle-maybe
org-babel-header-arg-expand)
 org-speed-command-hook '(org-speed-command-default-hook
org-babel-speed-command-hook)
 org-occur-hook '(org-first-headline-recenter)
 org-metaup-hook '(org-babel-load-in-session-maybe)
 org-html-format-drawer-function '(lambda (name contents) contents)
 org-latex-format-inlinetask-function 'ignore
 org-confirm-shell-link-function 'yes-or-no-p
 org-ascii-format-inlinetask-function 'org-ascii-format-inlinetask-default
 org-export-date-timestamp-format "%Y-%m-%d"
 org-latex-format-headline-function 'org-latex-format-headline-default-function
 org-after-todo-state-change-hook '(org-clock-out-if-current)
 org-latex-format-drawer-function '(lambda (name contents) contents)
 org-from-is-user-regexp nil
 org-src-mode-hook '(org-src-babel-configure-edit-buffer
org-src-mode-configure-edit-buffer)
 org-agenda-before-write-hook '(org-agenda-add-entry-text)
 org-babel-pre-tangle-hook '(save-buffer)
 org-export-copy-to-kill-ring t
 org-mode-hook '(#[nil "\300\301\302\303\304$\207" [org-add-hook
change-major-mode-hook org-show-block-all append local] 5]
         #[nil "\300\301\302\303\304$\207" [org-add-hook
change-major-mode-hook org-babel-show-result-all append local] 5]
         org-babel-result-hide-spec org-babel-hide-all-hashes)
 org-export-with-tags 'not-in-toc
 org-ascii-format-drawer-function '(lambda (name contents width) contents)
 org-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point
org-babel-execute-safely-maybe)
 org-cycle-hook '(org-cycle-hide-archived-subtrees
org-cycle-hide-drawers org-cycle-hide-inline-tasks
org-cycle-show-empty-lines
          org-optimize-window-after-visibility-change)
 org-export-with-drawers nil
 org-confirm-elisp-link-function 'yes-or-no-p
 org-metadown-hook '(org-babel-pop-to-session-maybe)
 org-html-format-headline-function 'ignore
 org-babel-load-languages '((ditaa . t))
 org-html-format-inlinetask-function 'ignore
 org-clock-out-hook '(org-clock-remove-empty-clock-drawer)
 org-publish-project-alist '(("website" :components ("website-content"))
                 ("website-content" :language "el" :base-directory
"~/org/chessblog/" :base-extension "org" :publishing-directory
                  "~/public_html/chessblog/" :recursive t
:publishing-function org-html-publish-to-html :export-with-tags nil
                  :headline-levels 3 :with-toc t :section-numbers nil
:auto-sitemap t :sitemap-filename "index.org" :sitemap-title
                  "Σκακιστική Προπόνηση" :timestamp t :exclude-tags
("noexport" "todo") :exclude "data.org"
                  :html-head-include-default-style nil
:html-html5-fancy t :html-link-use-abs-url t :html-link-home "."
:html-head
                  "<link rel=\"stylesheet\"
href=\"static/css/pure-release-0.5.0/pure.css\" type=\"text/css\">
<link rel=\"stylesheet\" href=\"static/css/org.css\"
type=\"text/css\"/> <link rel=\"stylesheet\"
href=\"static/css/worg.css\" type=\"text/css\"/> <link
rel=\"stylesheet\" href=\"static/css/solarized-light.css\"
type=\"text/css\"/>")
                 )
 )

             reply	other threads:[~2014-10-08 18:33 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-08 18:33 Gitsis Christos [this message]
2014-10-08 18:45 ` Bug: customizing HTML export postamble [8.2.7c (8.2.7c-61-g4b9146-elpa @ /home/christos/.emacs.d/elpa/org-20140908/)] Gitsis Christos
2014-10-08 21:54   ` Nick Dokos

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAHDzUL+fNGdzKbmuQoVw_QLGcQXeMLqdLWyeF=W3yewF4Q7h3g@mail.gmail.com' \
    --to=cgitsis@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).