[% msg = "hello" %]
[% (msg = msg _ " world") IF 0 %]
<p>[% msg %]</p>

The parens are needed for that to work?!

[% msg = msg _ " world" IF 0 %]

...blanks msg (highly surprising). I don't follow this list much these
days (a testament to the docs & general usability) but if there's a
vote to special case this bit of the grammar to DWIM, it gets my +1
:-)

I see this is somewhat explained here.
http://www.template-toolkit.org/docs/manual/Syntax.html#section_Capturing_Block_Output

Still, hmm.

P

_______________________________________________
templates mailing list
[email protected]
http://lists.template-toolkit.org/mailman/listinfo/templates

Reply via email to