]> sipb.mit.edu Git - ikiwiki.git/blob - doc/wikitemplates.mdwn
"safe" and "unsafe" too simplistic, I suspect
[ikiwiki.git] / doc / wikitemplates.mdwn
1 ikiwiki uses the HTML::Template module as its template engine. This
2 supports things like conditionals and loops in templates and is pretty easy
3 to learn.
4
5 The aim is to keep almost all html out of ikiwiki and in the templates.
6
7 It ships with some basic templates which can be customised. These are
8 located in `/usr/share/ikiwiki/templates` by default; the `templatedir`
9 setting can be used to make another directory be searched first.
10
11 * `page.tmpl` - Used for displaying all regular wiki pages.
12 * `misc.tmpl` - Generic template used for any page that doesn't
13   have a custom template.
14 * `editpage.tmpl` - Create/edit page.
15 * `change.tmpl` - Used to create a page describing a change made to the wiki.
16 * `passwordmail.tmpl` - Not a html template, this is used to
17   generate a mail with an url the user can use to reset their password.
18 * `rsspage.tmpl` - Used for generating rss feeds for [[blogs|blog]].
19 * `rssitem.tmpl` - Used for generating individual items on rss feeds.
20 * `atompage.tmpl` - Used for generating atom feeds for blogs.
21 * `atomitem.tmpl` - Used for generating individual items on atom feeds.
22 * `inlinepage.tmpl` - Used for adding a page inline in a blog
23   page.
24 * `archivepage.tmpl` - Used for listing a page in a blog archive page.
25 * `microblog.tmpl` - Used for showing a microblogging post inline.
26 * `blogpost.tmpl` - Used for a form to add a post to a blog (and a rss/atom links)
27 * `feedlink.tmpl` - Used to add rss/atom links if blogpost.tmpl is not used.
28 * `aggregatepost.tmpl` - Used by the [[plugins/aggregate]] plugin to create
29   a page for a post.
30 * `searchform.tmpl` - Used by the [[plugins/search]] plugin to add a search
31   form to wiki pages.
32 * `searchquery.tmpl` - This is an omega template, used by the
33   [[plugins/search]] plugin.
34 * `comment.tmpl` - This template is used to display a comment
35   by the [[plugins/comments]] plugin.
36 * `editcomment.tmpl` - This template is the comment post form for the
37   [[plugins/comments]] plugin.
38 * `commentmoderation.tmpl` - This template is used to produce the comment
39   moderation form.
40 * `recentchanges.tmpl` - This template is used for listing a change
41   on the RecentChanges page.
42
43 The [[plugins/pagetemplate]] plugin can allow individual pages to use a
44 different template than `page.tmpl`.
45
46 The [[plugins/template]] plugin also uses templates, though those
47 [[templates]] are typically stored as pages in the wiki, and are inserted
48 into pages.
49
50 The [[plugins/edittemplate]] plugin is used to make new pages default to
51 containing text from a template, which can be filled as out the page is
52 edited.