Setting a variable from within a template?

Stuart Moore <[email protected]> Thu, 23 Jul 2009 15:56:36 +0100
Newsgroups gmane.comp.lang.perl.modules.html-template
Message-ID <[email protected]>
Is there any way to set a variable within a template?

I'm looking to do something similar to

<TMPL_SETVAR TITLE="My Page's Title">
<TMPL_INCLUDE 'header.tmpl'>

To include a header template that has all the <HEAD> tags in (amongst
other stuff).

I can't see any way to do this - except possibly using some cunning
stuff with HTML::Template::Expr, and even then it's not clear exactly
how I'd do it.

I'm prepared to write some kind of patch myself that would do it, but
I thought it was worth checking if there was an existing method I'd
overlooked. I've tried searching the mailing list, but no joy.
(Apologies if I missed something)

Stuart Moore

------------------------------------------------------------------------------