@@ -41,14+41,17 @@ large chunks of marked up text to be embedded into a template:
To create a template, simply add a template directive to a page, and page will
provide a link that can be used to create the template. The template is a
To create a template, simply add a template directive to a page, and page will
provide a link that can be used to create the template. The template is a
-regular wiki page, located in the `templates/` directory.
+regular wiki (.mdwn) page, **located in the `templates/` directory** under source control. Nothing to do with **templatedir** from your ikiwiki configuration.
-The template uses the syntax used by the [[cpan HTML::Template]] perl
+The template uses the syntax used by the [[!cpan HTML::Template]] perl
module, which allows for some fairly complex things to be done. Consult its
documentation for the full syntax, but all you really need to know are a
few things:
module, which allows for some fairly complex things to be done. Consult its
documentation for the full syntax, but all you really need to know are a
few things:
-* To insert the value of a variable, use `<TMPL_VAR variable>`.
+* To insert the value of a variable, use `<TMPL_VAR variable>`. Wiki markup
+ in the value will first be converted to html.
+* To insert the raw value of a variable, with wiki markup not yet converted
+ to html, use `<TMPL_VAR raw_variable>`.
* To make a block of text conditional on a variable being set use
`<TMPL_IF NAME="variable">text</TMPL_IF>`.
* To use one block of text if a variable is set and a second if it's not,
* To make a block of text conditional on a variable being set use
`<TMPL_IF NAME="variable">text</TMPL_IF>`.
* To use one block of text if a variable is set and a second if it's not,