At least, following should work:
[% SET foo = 1 %]
[% IF foo.defined %] defined1 [% END %]
[% PERL %]
delete($stash->{foo});
[% END %]
[% IF foo.defined %] defined2 [% END %]
Does it help?
Best regards
Petr Danihlík
-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Felipe Gasper
(cPanel)
Sent: Friday, December 11, 2009 3:44 PM
To: [email protected]
Subject: [Templates] Can I "DELETE some_var"?
Is there a way to delete a variable from the stash in TT2?
If not, does something let me define a custom directive to do this?
-F
--
Felipe Gasper
Linux/BSD development
cPanel of Texas, LLC
3701 Kirby Dr., suite 428
Houston, TX 77098
office 713-529-0800 x4096
cell 832-633-8092
fax 713-559-3206
_______________________________________________
templates mailing list
[email protected]
http://mail.template-toolkit.org/mailman/listinfo/templates
_______________________________________________
templates mailing list
[email protected]
http://mail.template-toolkit.org/mailman/listinfo/templates