Re: [htmltmpl] Erro: You gave me an odd number of parameters to param()!
Brought to you by:
samtregar
From: Brad C. <bra...@hi...> - 2004-09-10 23:38:35
|
> > you passed the array instead of the array reference > >> $template -> param(pagetitle => "Search Results", >> showlist => @$allshows); > ^^^^ > > this is probably the correct one: > > $template -> param(pagetitle => "Search Results", > showlist => $allshows); > > > Gabor > Well, now I get: "Single reference arg to param() must be a hash-ref! You gave me a ARRAY" I guess I don't know how to go from @$array to $array as a ref. A Perlie question. Maybe I need to head over to the Monastery. Again, the salient code is: my $allshows; push @$allshows, $sth->fetchall_arrayref({}); $template -> param( showlist => $allshows); Thanks all. |