<?php
if ( ($PHP_AUTH_USER != "demo") || ($PHP_AUTH_PW != "demo")) {
Header("WWW-Authenticate: Basic realm=\"Для админов\"");
Header("HTTP/1.0 401 Unauthorized");
echo("<HTML>\n<HEAD>\n<TITLE>В доступе отказано!</TITLE>\n</HEAD>\n\n<BODY>\n\n<center><font size = 20 color=red><b>Access denied!</b></font></center><br><br><br>\n\n\n\n\n\n</BODY>\n</HTML>");
}
else {
$fp = fopen("../users/". $wmz, "r");
$dat = fgets($fp, 100);
$fp = fclose($fp);
list($ip,$email,$id,$cash,$times,$magicb,$cash2,$paid)=split(">>", $dat);
$cash2_1 = $cash + $summa;
$fp = fopen("../users/". $wmz, "w");
fwrite($fp, $ip. ">>". $email. ">>". $id. ">>". $cash2_1. ">>". $times. ">>". $magicb. ">>". $cash2. ">>". $paid);
$fp = fclose($fp);
echo "<br><br><br><br><br><br><br><br><br><center>". $summa ." WM переведены на кошелёк&nbsp". $wmz ."<br>";
echo "<a href=". $HTTP_REFERER .">Назад</a></center>";
}
?>