Размер файла: 2.04Kb
<?
Error_Reporting(E_ALL & ~E_NOTICE);
include_once("files/antixak.php");
list($msec,$sec)=explode(chr(32),microtime());
$HeadTime=$sec+$msec;
$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)!=="") {
if(@file("data/pk/$log.dat")){
$text = @file("data/pk/$log.dat");
$data = explode("||",$text[0]);
if(@file("data/pk/lose/$log.dat")){header ("Location: losepk.php?log=$log&pas=$pas"); exit;}
if(!@file("data/pk/$data[0].dat")){header ("Location: winpk.php?log=$log&pas=$pas"); exit;}
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=\"Персонаж\">";
echo "<p align=\"left\">";
$text = @file("data/pk/$log.dat");
$data = explode("||",$text[0]);
$text = @file("data/reg/$data[0].dat");
$data2 = explode(":||:",$text[0]);
if($udar=="0"){echo"<small>Вы промахнулись.<br/>- - -<br/></small>";}
if(!empty($udar)){echo"<small>Вы нанесли урон $udar<br/>- - -<br/></small>";}
echo"<small>HP противника: <b>[$data2[16]/$data2[17]]</b><br/>
HP ваше: <b>[$udata[16]/$udata[17]]</b><br/>- - -<br/>
<a href=\"udarpk.php?log=$log&pas=$pas\">Атака</a>
</small>";
}
}else{echo"<small>Пароль или логин неверен!</small>";}
include_once"files/down.php";
?>