You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jun 27, 2019. It is now read-only.
$top10 = $DB->getRows("SELECT p.id, p.img_src, caption, credit, sum(v.vote) AS total FROM photos p INNER JOIN votes v ON p.id = v.photo_id WHERE is_approved = 1 GROUP BY 1 ORDER BY 5 DESC LIMIT 10; ");
$Smarty->assign('top10', $top10);
$bottom10 = $DB->getRows("SELECT p.id, p.img_src, caption, credit, sum(v.vote) AS total FROM photos p INNER JOIN votes v ON p.id = v.photo_id WHERE is_approved = 1 GROUP BY 1 ORDER BY 5 ASC LIMIT 10; ");