How do I format the postamble in HTML-export with Org-mode?

前端 未结 2 1484
梦谈多话
梦谈多话 2021-02-09 01:02

I am creating a website with org-mode and would like to format the postamble so it just shows the date created and the creator at the bottom of the page, in the center, and is h

2条回答
  •  离开以前
    2021-02-09 01:14

    The reason it isn't accepting your own postamble is because you have to use #+BIND: syntax for the variable so that it is used on export. (See Export Options)

    After changing that setting I also had to adjust your format slightly to fit the required syntax. The default value for org-export-html-postamble-format is:

    (("en" "

    Author: %a (%e)

    Date: %d

    Generated by %c

    %v

    "))

    So you'd have to do the following to have it included (matching as closely as possible to that format):

    (setq org-export-html-postamble-format 
          '(("en" "

    Last Updated %d. Created by %c

    ")))

    This however will not center your text, it exports as follows:

    Last Updated 2012-03-16 16:22:03 Eastern Daylight Time. Created by Org version 7.8.03 with Emacs version 24

    I believe you'd have to set up a custom stylesheet with p.postamble { text-align: center; } to get the centering to work.

提交回复
热议问题