echo'
Letzten Foren";
$result = dbquery("SELECT tf.forum_id, tt.thread_id, tt.thread_subject, COUNT(tp.post_id) as count_posts FROM ".DB_PREFIX."forums tf INNER JOIN ".DB_PREFIX."threads tt USING(forum_id) INNER JOIN ".DB_PREFIX."posts tp USING(thread_id) WHERE ".groupaccess('forum_access')." GROUP BY thread_id ORDER BY count_posts DESC, thread_lastpost DESC LIMIT 5");
if (dbrows($result) != 0)
{
while($data = dbarray($result))
{
$itemsubject = trimlink($data['thread_subject'], 25);
echo "
$itemsubject\n";
}
}
else
{
echo "