----- Original Message -----
From: "Mark Stosberg" <[EMAIL PROTECTED]>
To: "Joel Gwynn" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Wednesday, December 19, 2001 4:42 PM
Subject: Re: [cgiapp] another HTML::Template question


> Joel Gwynn wrote:
> >
> > Using pv HTML::Template, I can do this:
> >
> > my $template = HTML::Template->new(filename => 'template.tmpl',
> >                                      associate => $query);
> >
> > where $query is my CGI object.
> >
> > I'm trying to do the same thing with CGI::App:
> >
> > my $q = $self->query;
> >    my $template = $self->load_tmpl(filename => 'template.html',
associate => $q);
> >
> > But I'm getting the message:
> >
> > HTML::Template->new() called with odd number of option parameters -
should be of the form option => value
> >
> > Can this be done?  If so, what is the syntax?
>
>
> Try this (untested):
> $self->load_tmpl('template.html',   associate => $q)
>
> I think the "filename" key is assumed.
>
>   -mark
>

Bingo!  Thanks.



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to