Page format
Every page contains a header, then a blank line, then the page body. This is the main text that end up in the rendered HTML page.
The header consists of several keywords, followed by a color and a space, and the the value. After this, the page body comes.
Page headerÂ
In the page header, you can define any attribute. Some of those keywords have special meaning for webber or it's plugins:
titleÂ
Full (long) title for the page. End's up in
"".
Very mandatory. Extremely important. You cannot have a page without a title. Never. Forget. The. Title.
Here's a Mako templates excerpt that uses this:
${file.title | entity}
...
${file.title
...
linktitleÂ
Sometimes the title is simply too long, e.g. for breadcrumbs. Therefore you can specify a link-title, which will be used by Generate hierarchy when generating breadcrumbs and a side-menu.
parentÂ
Used by Generate hierarchy to indicate relationship.
linksÂ
Used by Generate hierarchy to indicate relationship. Usually it's better to use
"parent" instead.
orderÂ
All pages with the same "parent" will end up below the parent on the
side-menu (see Generate hierarchy for details). They will be alphabetically sorted.
If you don't want this default sort order, you can specify your own ordering.
The default order is 100, so anything with a lower order will show up on the top, anything higher at the bottom of the side-menu.
ctimeÂ
Here you can specify an ISO formatted date and or time specifier, which contains the document creation date/time. Examples:
ctime: 2009-06-29
ctime: 2009-06-29 14:33
If you don't specify this, then the documents "mtime" will be used instead.
Here's a Mako templates excerpt that uses this:
<�f name="footer()">\
<%
mtime = format_date(file.mtime)
ctime = format_date(file.ctime)
%>
Created\
% if ctime == mtime:
${mtime} \
% else:
${ctime}, modified ${mtime} \
% endif
�f>\
This uses the named block feature of Mako, you can then place this text into your template with something like this:
${self.footer()}
mtimeÂ
Here you can specify an ISO formatted date and or time specifier, which contains the document modification date/time. Examples:
mtime: 2009-06-29
mtime: 2009-06-29 14:33
If you don't specify this, then the "last-modified"-time from the file-system will be used instead.
For an example, look at ctime above.
templateÂ
Allows you to override the default template. Just specify the pure file
name. For convenience, you can omit ".tmpl".
title: Blog
template: history
hideÂ
hide: true
will hide the generated page from in the plugins Generate hierarchy and Generate table of contents.
descriptionÂ
Anything you specify here will be accessible in the template as ${description}. You can use this for HTML meta information, see Mako templates.
If you don't specify a description, then ${description} will be the empty string.
Here's a Mako templates excerpt that uses this:
...
% if len(description):
% endif
...
keywordsÂ
Anything you specify here will be accessible in the template as ${keywords}. You can use this for HTML meta information, see Mako templates.
If you don't specify a description, then ${keywords} will be the empty string.
Here's a Mako templates excerpt that uses this:
...
% if len(keywords):
% endif
...
main_urlÂ
Used by Google Sitemap generation:
Internally, Webber works with relative URLs and is quite agnostic about URL of the final website. However, the Google Sitemap generation plugin needs absolute URLs, complete with host name.
Used by Google Sitemap generation:
sitemap_priorityÂ
Used by Google Sitemap generation to specify a relative important-ness of a page.
Should be between "0.0" and "1.0" (including).
sitemap_changefreqÂ
Used by Google Sitemap generation as an estimate about how often a page might change.
Should be one of the following values:
- always
- hourly
- daily
- weekly
- monthly
- yearly
- never
Your own keywordsÂ
Inside the template, functions and macros you can access all entries
by "file.XXXX" and you're free to invent your own keywords:
title: Impressum
subtitle: What you should know about this web-site
Hi, I'm Mario and I won't tell you more about me :-)
Now you can access "${file.subtitle}" in your template or
"params.file.subtitle" in your macros and
functions.
Page bodyÂ
Markdown page bodyÂ
Used for files ending with "*.md" and implemented by Read Markdown.
Here's an example:
title: Nothin' about me
Hi, I'm Holger and I won't tell you more about me :-)
RST formattedÂ
Used for files ending with "*.rst" and implemented by
Read RST.
HTML formattedÂ
Used for files ending with "*.html" and implemented by Read HTML.
This is actually not really HTML, only the page body is HTML. You can use it when RST or Markdown can't format the contents the way you like it, e.g. when using complex tables.
Here's an example:
title: Beruflicher Werdegang
linktitle: Werdegang
parent: Beruf
keywords: Lebenslauf, Werdegang
sitemap_changefreq: yearly
ctime: 2004-08-30
mtime: 2009-12-12
1979
1980
...
...
Â