mpolito1969 has asked for the wisdom of the Perl Monks concerning the following question:
Dear monks,
I've got a small question about accessing method "config" of HTML::Template from CGI::Application.
I'd like to do the equivalent of HTML::Template-> config(utf8 => 1) in a CGI::Application: what's the syntax for the method call?
I know I could use a reference to an object returned by load_tmpl() but this means I have to call load_tmpl() and only then I can configure the module:my $self = shift; my $tmplObj = $self->load_tmpl('myFile.tmpl', utf8 => 1); $tmplObj->config(utf8=>1);
Is this the best way? Can't I put the "config" call in other place so that its effect is already there when I call load_tmpl() in the first run mode?
Thanks
Bye,
Max
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: How to access HTML::Template method "config" from CGI::Application
by Anonymous Monk on Sep 19, 2016 at 23:05 UTC | |
by mpolito1969 (Initiate) on Sep 26, 2016 at 14:38 UTC |