]> sipb.mit.edu Git - ikiwiki.git/blob - doc/templates.mdwn
web commit by joey
[ikiwiki.git] / doc / templates.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 I aim to keep almost all html out of ikiwiki and in the templates.
6
7 It ships with some basic templates which can be customised:
8
9 * `templates/page.tmpl` - Used for displaying all regular wiki pages.
10 * `templates/misc.tmpl` - Generic template used for any page that doesn't
11   have a custom template.
12 * `templates/recentchanges.tmpl` - Used for the RecentChanges page.
13 * `templates/editpage.tmpl` - Create/edit page.
14 * `templates/passwordmail.tmpl` - Not a html template, this is used to
15   generate the mail with the user's password in it.
16 * `templates/rsspage.tmpl` - Used for generating rss feeds for [[blog]]s.
17 * `templates/inlinepage.tmpl` - Used for adding a page inline in a blog
18   page.
19 * `templates/inlinepagetitle.tmpl` - Used for listing a page inline in a blog
20   archive page.
21
22 If you like, you can add these to further customise it:
23
24 * `templates/signin.tmpl` - If it exists, it is used for customising the
25   layout of the SignIn form and all assciated forms. The misc.tmpl is
26   wrapped around this, so it should only be a template for the form.
27 * `templates/prefs.tmpl` - If it exists, it is used for customising the
28   layout of the Prefs form and all assciated forms. The misc.tmpl is
29   wrapped around this, so it should only be a template for the form.
30   
31 Note that the SignIn and Prefs forms are implemented using
32 CGI::FormBuilder, which interfaces to HTML::Template, so not all of it can
33 be customised with templates, although most of it can, by creating these
34 templates. Without the templates, CGI::FormBuilder creates the page bodies
35 by itself.