Welcome to the phpBoard demo site!

SQL Statement: $statement

"); $db_result = SQL_query($statement, $db_link); // find out how many results there were... $aff_rows = SQL_get_aff_rows($db_link, $db_result); //print("
There are currently $aff_rows categories.

\n"); $is_index = 1; top_bar(); // from lib_inc.php3 if ($aff_rows == 0) { print("

No categories found in this database... have you created them in the admin interface?\n"); SQL_close($db_link); include $inc_dir . "footer.php3"; exit; } print("\n"); print("\n"); // get each row for ($db_row = 0; $db_row < $aff_rows; $db_row++) { $row = SQL_fetch_array($db_result, $db_row); $group = $row["catgroup"]; $name = $row["name"]; if ((($db_row == 0) || ($group != $last_group)) && $use_category_groups) { print(""); } if ($db_row % 2) { print("\n"); } else { print("\n"); } $ref = $site_url . "browse" . $ext . "?category=" . urlencode($row["name"]); if ($row["password"]) { $pw_img = ""; } else { $pw_img = " "; } $st2 = "SELECT id FROM articles WHERE category='" . $row["name"] . "' AND approved=" . $row["moderated"]; $res = SQL_query($st2, $db_link); $posts = SQL_get_aff_rows($db_link, $res); if ($posts > 0) { $st2 = "SELECT posted,touched FROM articles WHERE category='" . $row["name"] . "' AND approved=" . $row["moderated"] . " ORDER BY touched DESC"; //print(""); $res2 = SQL_query($st2, $db_link); $rows = SQL_get_aff_rows($db_link, $res2); $row2 = SQL_fetch_array($res2, 0); $mydatetime = $row2["touched"]; $pret_time = make_time($mydatetime); $time_text = "\n"; $clast_name = "$site_name-" . $row["name"] . "-last"; $clast_name = eregi_replace(" ", "_", $clast_name); $clast = $HTTP_COOKIE_VARS["$clast_name"]; if ($clast == "") { $clast = 0; } $cuser = $HTTP_COOKIE_VARS["$cookie_name-username"]; if ($cuser == "") { if ($REMOTE_USER != "") { $cuser = $REMOTE_USER; } } $myunixtime = SQL_unixtime($db_link, $mydatetime); if ($cuser && $clast < $myunixtime) { $pw_img .= " "; } else { $pw_img .= " "; } } else { $time_text = "\n"; } print("\n"); print("$time_text"); if ($row["moderator"] == "") { print("\n"); } else { print("\n"); } $last_group = $group; } print("
 Forum NameDescriptionPosts in ForumLatest PostModerator(s)
$group
SQL: $st2  $pret_time $pw_img" . $row["name"] . "" . $row["description"] . "$postsUnmoderated
" . $row["moderator"] . "
\n"); SQL_close($db_link); // that's all for the moment, folks... include $inc_dir . "footer.php3"; ?>