parasew has asked for the wisdom of the Perl Monks concerning the following question:
this should now be processed via Template-Toolkit. but how can this be done? i have a subreturn( $sth->fetchall_arrayref);
i triedmy $t=Fs2::DBrequest::search_pl_entries(1,1,"a");
## first try ########################################## if ($c{a} eq "c_searchtest") { $vars = { search => $f }; } ########################################## ## second try my @f = @$t; if ($c{a} eq "c_searchtest") { $vars = { search => $t }; } ## and in the template [% FOREACH foo = f %] <pre> START THE OUTPUT [% foo.0 %] [% foo.1 %] </pre> [% END %] ##
any suggestions or examples out there?
thanks
parasew
update (broquaint): tidied up formatting
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: process lists of array_refs with Template-Toolkit
by jeffa (Bishop) on Oct 20, 2003 at 13:06 UTC | |
|
Re: process lists of array_refs with Template-Toolkit
by antirice (Priest) on Oct 20, 2003 at 11:13 UTC |