/////////////////////////////////////////////////////////////////////////////////// // // // phpBoard -- Copyright (c) 2000 by Nathan Clemons // // nathan@thelinuxcommunity.org // // // // This program is free software; you can redistribute it and/or modify // // it under the terms of the GNU General Public License as published by // // the Free Software Foundation; either version 2 of the License, or // // (at your option) any later version. // // // // This program is distributed in the hope that it will be useful, // // but WITHOUT ANY WARRANTY; without even the implied warranty of // // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // // GNU General Public License for more details. // // // // You should have received a copy of the GNU General Public License // // along with this program; if not, write to the Free Software // // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA // // // /////////////////////////////////////////////////////////////////////////////////// require "../config_inc.php3"; require $inc_dir . "lib_inc.php3"; require $inc_dir . $user_lib; include "adm_inc.php3"; $title = "$site_name"; if ($test_bgcolor && $test_bgcolor != $bgcolor) { $bgcolor = $test_bgcolor; } if ($test_bgtext && $test_bgtext != $bgtext) { $bgtext = $test_bgtext; } if ($test_thcolor && $test_thcolor != $thcolor) { $thcolor = $test_thcolor; } if ($test_trcolor && $test_trcolor != $trcolor) { $trcolor = $test_trcolor; } if ($test_trcolor1 && $test_trcolor1 != $trcolor1) { $trcolor1 = $test_trcolor1; } if ($test_trcolor2 && $test_trcolor2 != $trcolor2) { $trcolor2 = $test_trcolor2; } if ($test_mod_color && $test_mod_color != $mod_color) { $mod_color = $test_mod_color; } if ($test_adm_color && $test_adm_color != $adm_color) { $adm_color = $test_adm_color; } if ($test_link && $test_link != $link) { $link = $test_link; } if ($test_alink && $test_alink != $alink) { $alink = $test_alink; } if ($test_vlink && $test_vlink != $vlink) { $vlink = $test_vlink; } include $inc_dir . "header.php3"; ?> print("
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("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("
| Forum Name | Description | Posts in Forum | Latest Post | Moderator(s) | |||
|---|---|---|---|---|---|---|---|
| $group | |||||||
| $pw_img | " . $row["name"] . " | " . $row["description"] . " | \n"); $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); print("$posts | "); if ($posts > 0) { $st2 = "SELECT posted FROM articles WHERE category='" . $row["name"] . "' AND approved=" . $row["moderated"] . " ORDER BY posted DESC"; //print("SQL: $st2 | "); $res2 = SQL_query($st2, $db_link); $rows = SQL_get_aff_rows($db_link, $res2); $row2 = SQL_fetch_array($res2, 0); $mydatetime = $row2["posted"]; $pret_time = make_time($mydatetime); print("$pret_time | \n"); } else { print("\n"); } if ($row["moderator"] == "") { print(" | Unmoderated | " . $row["moderator"] . " | \n"); } $last_group = $group; } print("