]> sipb.mit.edu Git - ikiwiki.git/blob - doc/templates.mdwn
add dep on libtimedate-perl for str2time
[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 * `estseek.conf` - Not a html template, this is actually a template for
22   a config file for the [[HyperEstraier]] search engine. If you like you
23   can read the [[HyperEstraier]] docs and configure it using this.
24
25 If you like, you can add these to further customise it:
26
27 * `templates/signin.tmpl` - If it exists, it is used for customising the
28   layout of the SignIn form and all assciated forms. The misc.tmpl is
29   wrapped around this, so it should only be a template for the form.
30 * `templates/prefs.tmpl` - If it exists, it is used for customising the
31   layout of the Prefs form and all assciated forms. The misc.tmpl is
32   wrapped around this, so it should only be a template for the form.
33   
34 Note that the SignIn and Prefs forms are implemented using
35 CGI::FormBuilder, which interfaces to HTML::Template, so not all of it can
36 be customised with templates, although most of it can, by creating these
37 templates. Without the templates, CGI::FormBuilder creates the page bodies
38 by itself.