From f04611a6d0e4738810dfa5af63cb06a33b45a4f5 Mon Sep 17 00:00:00 2001 From: smcv Date: Wed, 18 Feb 2015 19:38:26 -0400 Subject: already fixed in newer ikiwiki --- doc/bugs/trailitems_fails_inside_template.mdwn | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/doc/bugs/trailitems_fails_inside_template.mdwn b/doc/bugs/trailitems_fails_inside_template.mdwn index 477745793..bf401a7b2 100644 --- a/doc/bugs/trailitems_fails_inside_template.mdwn +++ b/doc/bugs/trailitems_fails_inside_template.mdwn @@ -26,3 +26,28 @@ My ikiwiki version: 3.20130904 Huge thanks in advance! --[[fr33domlover]] + +> These templates have traditionally had a problem: they need to be +> simultaneously a valid page in their own right, and a valid page after +> template substitutions. +> +> In newer ikiwiki versions, the [[ikiwiki/directive/templatebody]] +> directive [[solves this|done]] ... but your ikiwiki is nearly a year +> and a half old, so you don't have recent bugfixes. +> +> You might be able to get somewhere by abusing the two intersecting +> markup languages, something like this: +> +> +> \[[!if test="included() and !included()" then=""" +> +> ... real content here: inline, trailitems etc. ... +> ... just don't use a triple quote mark ... +> +> """]] +> +> +> Alternatively, if you have direct commit access and don't need +> to be able to perform web-based edits on your template, I think +> renaming your template from `foo.mdwn` to `foo.tmpl` would bypass +> this while still working as a template. --[[smcv]] -- cgit v1.2.3