\n"); print("
\n"); print("\n"); $db_link = SQL_connect(); // form the select statement $statement = "SELECT * FROM categories WHERE name='$cat_name'"; // output it... helpful for debugging purposes... //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); if ($aff_rows == 0) { print("

No such category found in this database...\n"); SQL_close($db_link); include $inc_dir . "footer.php3"; exit; } else if ($aff_rows > 1) { print("

More than one category found... data is not sane, aborting.\n"); SQL_close($db_link); include $inc_dir . "footer.php3"; exit; } $row = SQL_fetch_array($db_result, 0); $moderated = $row["moderated"]; $moderator = $row["moderator"]; $descript = $row["description"]; $pass = $row["password"]; $group = $row["catgroup"]; print("

\n"); if ($moderated) { print("\n"); } else { print("\n"); } print("\n"); print("\n"); print("\n"); print("\n"); print("\n"); print("
Edit Category
Name  $cat_name
Moderated  No Yes
Moderated  No Yes
Moderator Name  
Category Description  
Password  
Group  
\n"); include $inc_dir . "footer.php3"; ?>