Hi,

in Perl it is possible to use a hash value to call a function like this:

my $content = $subs{'index'};

my %subs = (
    "index" => \&index,
    "logout" => \&logout,
   ...
);

sub index {...}
...

Is there also a TT way to group MACROS like this?

[%

MACRO checked(val) BLOCK;
    IF ...
    END;
END;

html = {
    checked = ???
}

-%]

So you could call  [% html.checked('foo') %] ?

I hope there is a way :-)

Michael


____________________________________________________________________
Psssst! Schon vom neuen WEB.DE MultiMessenger gehört? 
Der kann`s mit allen: http://www.produkte.web.de/messenger/?did=3123


_______________________________________________
templates mailing list
templates@template-toolkit.org
http://mail.template-toolkit.org/mailman/listinfo/templates

Reply via email to