File size: 1.78Kb
<?php
header ("Content-type:application/xhtml+xml; charset=utf-8");
header("Cache-Control: no-store, no-cache, must-revalidate");
include("core.php"); //load main functions
include("conf.php"); //load config
echo $style2;
$who=$_GET["who"];
$days=$_POST["days"];
$hours=$_POST["hours"];
$minutes=$_POST["minutes"];
$seconds=$_POST["seconds"];
$reason=$_POST["reason"];
echo connect($dbuser,$dbpass,$dbserver,$dbname);
//$name=base64_decode($name);
echo login($nick,$pass);
echo "<br/><br/>";
global $logged;
if ($logged)
{
ismod2($nick,$pass);
global $moderator;
if (!$moderator) echo "You are not allowed to do this!"; else
{
if ($days=="") $days=0;
if ($hours=="") $hours=0;
if ($minutes=="") $minutes=0;
if ($seconds=="") $seconds=0;
$bannedto=time()+$seconds+($minutes*60)+($hours*60*60)+($days*24*60*60);
$reason=str_replace("$","",$reason);
$reason=str_replace("<","",$reason);
$reason=str_replace("<","",$reason);
$reason=str_replace(">","",$reason);
$reason=str_replace(">","",$reason);
$reason=str_replace("\"","",$reason);
$reason=str_replace("'","",$reason);
$reason=str_replace("\\","",$reason);
$reason=str_replace("&","",$reason);
echo ban($nick,$pass,$who,$bannedto,$reason);
};
};
echo "<a href=\"index.php?nick=$nick&pass=$pass\">BACK</a>";
echo $endhtml;
?>