my $template = undef; #calls foo &foo #outputs page print $template->output; sub foo { $template = HTML::Template->new(filename => 'test.tmpl'); # fill in some parameters in the template $template->param(home => $ENV{HOME}); $template->param(path => $ENV{PATH}); }
In reply to Variable and object scoping by Angel
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |