no more misc.tmpl
* Removed misc.tmpl. Now to theme ikiwiki, you only need to customise a single template, page.tmpl. * misc.tmpl will, however, still be read if a locally modified version exists. This is to avoid forcing users to update page.tmpl right now.master
parent
2a2976f7ff
commit
66cc23a591
30
IkiWiki.pm
30
IkiWiki.pm
|
@ -1742,21 +1742,29 @@ sub template ($;@) {
|
|||
|
||||
sub misctemplate ($$;@) {
|
||||
my $title=shift;
|
||||
my $pagebody=shift;
|
||||
my $content=shift;
|
||||
|
||||
my $template=template("misc.tmpl");
|
||||
$template->param(
|
||||
title => $title,
|
||||
indexlink => indexlink(),
|
||||
wikiname => $config{wikiname},
|
||||
pagebody => $pagebody,
|
||||
baseurl => baseurl(),
|
||||
html5 => $config{html5},
|
||||
@_,
|
||||
);
|
||||
my $template=template("misc.tmpl") || template("page.tmpl");
|
||||
|
||||
run_hooks(pagetemplate => sub {
|
||||
shift->(page => "", destpage => "", template => $template);
|
||||
});
|
||||
|
||||
$template->param(
|
||||
title => $title,
|
||||
wikiname => $config{wikiname},
|
||||
content => $content,
|
||||
baseurl => baseurl(),
|
||||
html5 => $config{html5},
|
||||
have_actions => 0, # force off
|
||||
searchform => 0, # ditto
|
||||
parentlinks => [{ # override
|
||||
url => $config{url},
|
||||
page => $config{wikiname},
|
||||
}],
|
||||
@_,
|
||||
);
|
||||
|
||||
return $template->output;
|
||||
}
|
||||
|
||||
|
|
|
@ -1,3 +1,12 @@
|
|||
ikiwiki (3.20100505) UNRELEASED; urgency=low
|
||||
|
||||
* Removed misc.tmpl. Now to theme ikiwiki, you only need to customise
|
||||
a single template, page.tmpl.
|
||||
* misc.tmpl will, however, still be read if a locally modified version
|
||||
exists. This is to avoid forcing users to update page.tmpl right now.
|
||||
|
||||
-- Joey Hess <joeyh@debian.org> Wed, 05 May 2010 18:07:29 -0400
|
||||
|
||||
ikiwiki (3.20100504) unstable; urgency=low
|
||||
|
||||
* Add parameter to displaytime to specify that it is a pubdate,
|
||||
|
|
|
@ -81,6 +81,9 @@ Probably incomplete list:
|
|||
* Enable tagbase by default (so that tag autocreation will work by default).
|
||||
Note that this is already done for wikis created by `auto-blog.setup`.
|
||||
* [[tips/html5]] on by default (some day..)
|
||||
* stop reading misc.tmpl if it exists (only done in case users have a customized
|
||||
version, or an outdated version of page.tmpl that cannot be used by
|
||||
misctemplate)
|
||||
|
||||
In general, we try to use [[ikiwiki-transition]] or forced rebuilds on
|
||||
upgrade to deal with changes that break compatability. Some things that
|
||||
|
|
|
@ -45,8 +45,6 @@ html out of ikiwiki and in the templates.
|
|||
key template to customize. [[!if test="enabled(pagetemplate)" then="""
|
||||
(The pagetemplate directive can be used to make a page use a
|
||||
different template than `page.tmpl`.)"""]]
|
||||
* `misc.tmpl` - Generic template used for any page that doesn't
|
||||
have a custom template.
|
||||
* `rsspage.tmpl` - Used for generating rss feeds for blogs.
|
||||
* `rssitem.tmpl` - Used for generating individual items on rss feeds.
|
||||
* `atompage.tmpl` - Used for generating atom feeds for blogs.
|
||||
|
|
Loading…
Reference in New Issue