$template->output(print_to => \*FILE);
In general, the syntax for named parameters is
optionally with a hyphen in front of the name, which makes it look like a command line option (and which should ring the "familiarity" bell); and which makes it stand out a little more:func(name => $value, ...); $obj->method(name => $value, ...);
In case you find this baffling: the autoquoting rule for the left hand side of "=>" also applies to barewords preceded with a hyphen. So, (-name => 'value') is interpreted by Perl as ('-name', 'value').func(-name => $value, ...); $obj->method(-name => $value, ...);
But, from the source I would gather that HTML::Template doesn't honour this tradition, by which I mean it likely won't recognize $template->output(-print_to => \*FILE); . However, I musty admit I haven't tested it.
In reply to Re: Re: Re: HTML::Template output to file
by bart
in thread HTML::Template output to file
by jonnyfolk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |