File size: 1.54Kb
<?
Error_Reporting(E_ALL & ~E_NOTICE);
$ref=rand(100,10000000);
header("Content-type:text/vnd.wap.wml");
echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?>";
echo "<!DOCTYPE wml PUBLIC \"-//WAPFORUM//DTD WML 1.2//EN\" \"http://www.wapforum.org/DTD/wml12.dtd\">";
echo "<wml>\n";
echo "<head><meta http-equiv=\"Cache-Control\" content=\"no-cache\" forua=\"true\"/></head>";
echo "<card id=\"index\" title=\"GM-panel\">";
echo "<p align=\"left\">";
$log = htmlspecialchars(stripslashes($log));
$pas = htmlspecialchars(stripslashes($pas));
/////////////////////////////////////////////////////
$text = @file("../data/reg/$log.dat");
if ($text!=""){
$udata = explode(":||:",$text[0]);
$login=trim($udata[0]);
$password=trim($udata[1]);}
////////////////////////////////////////////////////////
if (md5($pas)==$password && $log==$login && $log!=="" && md5($pas)!=="") {
$u = explode(".",$login);
if($log=="$u[0].GM"){
$time=time()-3600;
$dir = opendir ("../data/msg");
while ($file = readdir ($dir))
{
if (( $file != ".") && ($file != "..")){
$file2=@file("../data/msg/$file");
$GLOBALS[total]=count($file2);
$GLOBALS[all]=$GLOBALS[all]+$GLOBALS[total];
@unlink ("../data/msg/$file");
}
}
if($GLOBALS[all]==""){$GLOBALS[all]="0";}
echo"<small>Удалено: $GLOBALS[all] писем.</small>";
}
}else{echo"<small>Пароль или логин неверен!</small>";}
echo "</p></card></wml>";
?>