We are trying to change the output on the Top5 global. Here is the global:
sub {
my $tags = shift;
my $table = $DB->table('Links');
$table->select_options ('ORDER BY Hits DESC', 'LIMIT 5');
my $sth = $table->select;
my @output;
while (my $link = $sth->fetchrow_hashref) {
push (@output, $link);
}
return { top5_loop => \@output };
}
On other globals we used the following formatting code:
$output .= Links::SiteHTML::display ('link', $link)
How can we incorporate this formatting in the global?
sub {
my $tags = shift;
my $table = $DB->table('Links');
$table->select_options ('ORDER BY Hits DESC', 'LIMIT 5');
my $sth = $table->select;
my @output;
while (my $link = $sth->fetchrow_hashref) {
push (@output, $link);
}
return { top5_loop => \@output };
}
On other globals we used the following formatting code:
$output .= Links::SiteHTML::display ('link', $link)
How can we incorporate this formatting in the global?