You know what. I answered this earlier, but something in the back of my mind just told me to look at the code again. I made a stupid boo-boo. There's a } in the wrong place, so no, the current hack will not work correctly. However, if you download it, and make the following change to the while loop, it should. Don't forget to make the & changes I listed above either. I'll post an updated version tomorrow.
Code:
while($post = $DB_site->fetch_array($posts))
{
$perms = fetch_permissions($post['forumid']);
// if no rows set this then the section will be skipped on display
if($perms & CANVIEW || $perms & CANVIEWOTHERS){
$latestpostcount++;
$post['threadtitle'] = fetch_censored_text(fetch_trimmed_title(unhtmlspecialchars($post['threadtitle']), 22));
$post['forumtitle'] = fetch_censored_text(fetch_trimmed_title(unhtmlspecialchars($post['forumtitle']), 22));
$post['replycount'] = vb_number_format($post['replycount']);
$post['views'] = vb_number_format($post['views']);
// keep this in case you want to use alternating colors
exec_switch_bg();
eval("\$latestpostbits .= \"".fetch_template('forumhome_latestpostbits')."\";");
}
}
Good call mate.