require("include/top.php");
if ($which && ($SESSION_LEVEL=='administrator' || $SESSION_LEVEL=='moderator' || $SESSION_LEVEL=='gloperator')):
// check the submitted data
unset($submitok);
if($name)
{
// check user account
if(!isset($_SESSION['SESSION']))
$errormessage[]="you need to be logged in first.";
if(($SESSION_LEVEL!='administrator')&&($SESSION_LEVEL!='moderator')&&($SESSION_LEVEL!='gloperator'))
$errormessage[]="you need to be a lobster god to edit a bbs.";
// check prod id
$result=mysql_query("SELECT count(0) FROM lists WHERE id=$which");
if(mysql_result($result,0)!=1)
$errormessage[]="I can't find the list you are trying to modify";
// if everything is ok
if(!$errormessage)
$submitok=true;
}
// insert the submitted bbs
if($submitok){
$query = "UPDATE lists SET ";
$query.= "lists.name='".$name."', ";
$query.= "lists.desc='".$desc."', ";
$query.= "upkeeper='".$upkeeper."' ";
$query.= "WHERE id=$which LIMIT 1";
//print($query);
mysql_query($query);
logGloperatorAction("list_edit",$which);
}
// get data to build the page
$result = mysql_query("SELECT * FROM lists WHERE id=$which");
$lists = mysql_fetch_assoc($result);
?>
the lobster says "NO ENTRANCE!"
you need god priveligies to access this place.
it's also possible that you forgot a ?which=xxx
else: ?>