else 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 "<card id=\"main\" title=\"Mod CP\">";
echo "<p align=\"center\">";
$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(trim($pres)=="")
{
echo "<img src=\"images/notok.gif\" alt=\"X\"/>You must Specify a reson for punishing the user";
}else{
$timeto = $pds*24*60*60;
$timeto += $phr*60*60;
$timeto += $pmn*60;
$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='[b]".getnick_uid(getuid_sid($sid))."[/b] $pmsg[$pid] The user [b]".$unick."[/b] 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 "</p></card>";
}
i think this is where i should add that right? but i did somethin is going wrong External image (may be gone)