一般情况下,「C-c C-e h」就能导出org文件为html格式的了。输入「C-c C-e t」会在org文件中输入当前的导出模板,如下所示,可以针对该org文件修改该模板。
#+TITLE: the title to be shown (default is the buffer name)#+AUTHOR: the author (default taken from user-full-name)#+DATE: a date, an Org timestamp119, or a format string for format-time-string#+EMAIL: his/her email address (default from user-mail-address)#+DESCRIPTION: the page description, e.g. for the XHTML meta tag#+KEYWORDS: the page keywords, e.g. for the XHTML meta tag#+LANGUAGE: language for HTML, e.g. ‘en’ (org-export-default-language)#+TEXT: Some descriptive text to be inserted at the beginning.#+TEXT: Several lines may be given.#+OPTIONS: H:2 num:t toc:t \n:nil @:t ::t |:t ^:t f:t TeX:t ...#+BIND: lisp-var lisp-val, e.g.: org-export-latex-low-levels itemize You need to confirm using these, or configure org-export-allow-BIND#+LINK_UP: the ``up'' link of an exported page#+LINK_HOME: the ``home'' link of an exported page#+LATEX_HEADER: extra line(s) for the LaTeX header, like \usepackage{xyz}#+EXPORT_SELECT_TAGS: Tags that select a tree for export#+EXPORT_EXCLUDE_TAGS: Tags that exclude a tree from export#+XSLT: the XSLT stylesheet used by DocBook exporter to generate FO file
其中OPTIONS选项的含义如下:
H: set the number of headline levels for exportnum: turn on/off section-numberstoc: turn on/off table of contents, or set level limit (integer)\n: turn on/off line-break-preservation (DOES NOT WORK)@: turn on/off quoted HTML tags:: turn on/off fixed-width sections|: turn on/off tables^: turn on/off TeX-like syntax for sub- and superscripts. If you write "^:{}", a_{b} will be interpreted, but the simple a_b will be left as it is.-: turn on/off conversion of special strings.f: turn on/off footnotes like this[1].todo: turn on/off inclusion of TODO keywords into exported texttasks: turn on/off inclusion of tasks (TODO items), can be nil to remove all tasks, todo to remove DONE tasks, or list of kwds to keeppri: turn on/off priority cookiestags: turn on/off inclusion of tags, may also be not-in-toc<: turn on/off inclusion of any time/date stamps like DEADLINES*: turn on/off emphasized text (bold, italic, underlined)TeX: turn on/off simple TeX macros in plain textLaTeX: configure export of LaTeX fragments. Default autoskip: turn on/off skipping the text before the first headingauthor: turn on/off inclusion of author name/email into exported fileemail: turn on/off inclusion of author email into exported filecreator: turn on/off inclusion of creator info into exported filetimestamp: turn on/off inclusion creation time into exported filed: turn on/off inclusion of drawers
当然其中有些选项并不是只针对导出html的,也有针对导出pdf文件的,这个会在接下去的章节进行介绍。
联系客服