Re: Leaving tmp_var intact inside template

Roger Burton West <[email protected]> Sun, 3 Aug 2008 16:54:07 +0100
Newsgroups gmane.comp.lang.perl.modules.html-template
Message-ID <[email protected]>
On Tue, Jul 29, 2008 at 09:01:45AM -0400, Brad Baxter wrote:

>Using !TMPL_VAR would allow for "3-pass" or "n-pass" templating.  That
>is, change !TMPL_VAR to TMPL_VAR on each pass.  If you then have
>!!TMPL_VAR, it survives to the third pass.
>
>I actually do this (albeit with a different templating system), though I can
>recall only a couple of times I ever needed !!.

I'm using something similar at work - though my syntax is "2MPL_VAR"
(which is similarly extensible, though I haven't needed a 3-pass system
yet). The entire static page tree of the site is run through an H::T
pass before upload to generate navigation data (headers, footers, etc.),
so any actual template-based content needs special treatment.

Roger

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/