<% $header %>

<% $description %>
<& ../lib/teasNav.mas, category => "coffee", sub_category => "best_reviewed" &>
<% $copy %>
<%init> our ($userIdGlobal, $showInGlobal); my ($sql, $sth); my $dbh = $m->comp('/dbconnect.mas'); my $copy; my $counter = 0; $sql = qq| SELECT ID FROM product_description WHERE $showInGlobal = 1 AND STATUS = 1 ORDER BY ORDER_RATING DESC LIMIT 8 |; $sth = $dbh->prepare($sql); $sth->execute(); while (my ($id) = $sth->fetchrow_array()) { $copy .= $m->comp('../lib/product_thumbnail.mas', productName=>$id, friends=>3, personalReview=>$userIdGlobal); $counter++; } my $header = "Best Reviewed"; my $description = "Curious to see which are the best-reviewed? Here's an up-to-date listing of our best-reviewed items:"; <%attr> title => 'WEBSITE_NAME - Best Reviewed List'