public function forumIndex() {
echo '
';
$catQuery = "SELECT * FROM `runeorb_forum_categories`";
$catResult = mysql_query($catQuery);
if ($catResult >= 1) {
while ($cat = mysql_fetch_assoc($catResult)) {
echo
"\n\t" . '' .
"\n\t" . '| ' . $cat['Name'] . ' | ' .
"\n\t" . 'Topics | ' .
"\n\t" . 'Posts | ' .
"\n\t" . 'Last post | ' .
"\n\t" . '
';
$forumQuery = "SELECT * FROM `runeorb_forum_forums` WHERE `Category` = '" . $cat['Name'] . "'";
$forumResult = mysql_query($forumQuery);
if ($forumResult >= 1) {
while ($forum = mysql_fetch_assoc($forumResult)) {
echo
"\n\t" . '' .
"\n\t" . '' . $forum['Name'] . ' ' . $forum['Description'] . ' | ' .
"\n\t" . '' . $forum['Topics'] . ' | ' .
"\n\t" . '' . $forum['Posts'] . ' | ' .
"\n\t" . 'In:' . $forum['In'] .' By:' . $forum['By'] . ' At:' . $forum['At'] . ' | ' .
"\n\t" . '
';
}
}
}
}
echo '