// Fetch data
$query = $db->query("SELECT ".TABLE_PREFIX."posts.subject, ".TABLE_PREFIX."threads.lastposter, ".TABLE_PREFIX."threads.lastposteruid, ".TABLE_PREFIX."posts.pid, ".TABLE_PREFIX."posts.tid, ".TABLE_PREFIX."posts.icon, ".TABLE_PREFIX."threads.lastpost
FROM ".TABLE_PREFIX."posts, ".TABLE_PREFIX."threads
WHERE ".TABLE_PREFIX."posts.visible='1' AND ".TABLE_PREFIX."threads.lastpost <= ".TABLE_PREFIX."posts.dateline AND ".TABLE_PREFIX."posts.fid NOT IN ({$overview_unviewable}5,42,43,8,9,10,11,38)
AND ".TABLE_PREFIX."posts.tid=".TABLE_PREFIX."threads.tid
GROUP BY ".TABLE_PREFIX."posts.tid
ORDER BY ".TABLE_PREFIX."threads.lastpost DESC
LIMIT 0,{$settings['overview_max']};");
// Print data
while($posts = $db->fetch_array($query))
{
$val1 = overview_parsesubject($posts['subject'], $posts['icon'], 0, $posts['tid'], $posts['pid'], 0, 1);
$val2 = overview_parseuser($posts['lastposteruid'], $posts['lastposter']);
eval("\$table_content .= \"".$templates->get("overview_2_columns_row")."\";");
}