Pls all wap masters and code master
I already have modcp and modproc.php including hack proof script. But i want scipt by that any moderator cant ban,trash or ip ban admin. They can ban or other penalties to user except admin. To grow up site i need good mods as i had already appointed. They are good but i need this arrangement so they cant ban admins .i do script in modproc.php but it not worked
Check plsCODEelse if($action=="pun") { $pid = $_POST["pid"]; $who = $_POST["who"]; $pres = $_POST["pres"]; $pds = $_POST["pds"]; $phr = $_POST["phr"]; $pmn = $_POST["pmn"]; $psc = $_POST["psc"]; echo " ";
$uip = ""; $ubr = ""; $pmsg[0]="Trashed"; $pmsg[1]="Banned"; $pmsg[2]="IP-Banned"; if($pid=='2') { //ip ban $uip = getip_uid($who); $ubr = getbr_uid($who); } if(!isadmin(getuid_sid($sid))) { $sql = mysql_fetch_array(mysql_query("SELECT uid FROM ibwf_users WHERE id='".$who."'")); $uip = getip_uid($who); $ubr = getbr_uid($who); echo "<img src="../images/notok.gif" alt="X"/>u cant ban admin"; }else{
if(trim($pres)=="") { echo "<img src="../images/notok.gif" alt="X"/>You must Specify a reson for punishing the user"; }else{ $timeto = $pds246060; $timeto += $phr6060; $timeto += $pmn60; $timeto += $psc; $ptime = $timeto + time(); $unick = getnick_uid($who); $res = mysql_query("INSERT INTO ibwf_penalties SET uid='".$who."', penalty='".$pid."', exid='".getuid_sid($sid)."', timeto='".$ptime."', pnreas='".mysql_escape_string($pres)."', ipadd='".$uip."', browserm='".$ubr."'"); if($res) { mysql_query("UPDATE ibwf_users SET lastpnreas='".$pmsg[$pid].": ".mysql_escape_string($pres)."' WHERE id='".$who."'"); mysql_query("INSERT INTO ibwf_mlog SET action='penalties', details='".getnick_uid(getuid_sid($sid))." $pmsg[$pid] The user ".$unick." For ".$timeto." Seconds', actdt='".time()."'");
echo "<img src=\"../images/ok.gif\" alt=\"O\"/>$unick is $pmsg[$pid] for $timeto Seconds";
}else{
echo "<img src=\"../images/notok.gif\" alt=\"X\"/>Database Error";
}
} echo "
<a href="index.php?action=main&sid=$sid"><img src="../images/home.gif" alt="*"/>"; echo "Home</a>"; echo "
</body>"; }