game/dn_editor_bots_itms.php

86 lines
3.2 KiB
PHP
Raw Normal View History

2022-06-06 21:30:34 +00:00
<?
session_start();
function er($e)
{
global $c;
die('<html><head><meta http-equiv="Content-Type" content="text/html; charset=windows-1251"><meta http-equiv="Content-Language" content="ru"><TITLE><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD></TITLE></HEAD><BODY text="#FFFFFF"><p><font color=black><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>: <pre>'.$e.'</pre><b><p><a href="https://'.$c[0].'/"><3E><><EFBFBD><EFBFBD><EFBFBD></b></a><HR><p align="right">(c) <a href="https://'.$c[0].'/">'.$c[1].'</a></p></body></html>');
}
function GetRealIp()
{
if(!empty($_SERVER['HTTP_CLIENT_IP'])) {
$ip=$_SERVER['HTTP_CLIENT_IP'];
}elseif(!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) {
$ip=$_SERVER['HTTP_X_FORWARDED_FOR'];
}else{
$ip=$_SERVER['REMOTE_ADDR'];
}
return $ip;
}
define('IP',GetRealIp());
define('GAME',true);
include_once('_incl_data/__config.php');
include_once('_incl_data/class/__db_connect.php');
include_once('_incl_data/class/__user.php');
if($u->info['admin'] == 0) {
die('<meta http-equiv="refresh" content="0; URL=https://new-combats.com/">');
}
?>
<form method="post" action="?gotonew">
id <EFBFBD><EFBFBD><EFBFBD><EFBFBD>: <input name="id_bot" value="<?=$_POST['id_bot']?>"><br>
<input type="submit" value="<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>">
</form>
--------------- <EFBFBD><EFBFBD><EFBFBD> -------------<br>
<?
$pl = mysql_fetch_array(mysql_query('SELECT * FROM `test_bot` WHERE `id` = "'.mysql_real_escape_string($_POST['id_bot']).'" LIMIT 1'));
if(isset($pl['id'])) {
if(isset($_GET['save'])) {
mysql_query('UPDATE `test_bot` SET
`login` = "'.mysql_real_escape_string($_POST['login']).'",
`obraz` = "'.mysql_real_escape_string($_POST['obraz']).'",
`level` = "'.mysql_real_escape_string($_POST['level']).'",
`sex` = "'.mysql_real_escape_string($_POST['sex']).'",
`name` = "'.mysql_real_escape_string($_POST['name']).'",
`agressor` = "'.mysql_real_escape_string($_POST['agressor']).'",
`expB` = "'.mysql_real_escape_string($_POST['expB']).'",
`stats` = "'.mysql_real_escape_string($_POST['stats']).'",
`itemsUse` = "'.mysql_real_escape_string($_POST['itemsUse']).'",
`p_items` = "'.mysql_real_escape_string($_POST['p_items']).'" WHERE `id` = "'.$pl['id'].'"
LIMIT 1');
$pl = mysql_fetch_array(mysql_query('SELECT * FROM `test_bot` WHERE `id` = "'.mysql_real_escape_string($_POST['id_bot']).'" LIMIT 1'));
}
?>
<form method="post" action="?gotonew&save"><input type="hidden" name="id_bot" value="<?=$_POST['id_bot']?>">
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>: <input name="login" value="<?=$pl['login']?>"><br />
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>: <input name="obraz" value="<?=$pl['obraz']?>"><br />
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>: <input name="level" value="<?=$pl['level']?>"><br />
<EFBFBD><EFBFBD><EFBFBD>: <input name="sex" value="<?=$pl['sex']?>"> (0 - <EFBFBD><EFBFBD><EFBFBD>. , 1 - <EFBFBD><EFBFBD><EFBFBD>.)<br />
<EFBFBD><EFBFBD><EFBFBD>: <input name="name" value="<?=$pl['name']?>"><br />
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>: <input name="agressor" value="<?=$pl['agressor']?>"> (0-100%)<br />
<EFBFBD><EFBFBD><EFBFBD><EFBFBD> (%): <input name="expB" value="<?=$pl['expB']?>"><br />
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>:<br />
<textarea rows="5" cols="75" name="stats"><?=$pl['stats']?></textarea>
<br />
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> (<EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD>, 2605 - <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>. <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> id <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>):<br />
<textarea rows="5" cols="75" name="itemsUse"><?=$pl['itemsUse']?></textarea>
<br />
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <EFBFBD> <EFBFBD><EFBFBD><EFBFBD><EFBFBD>:<br />
<textarea rows="5" cols="75" name="p_items"><?=$pl['p_items']?></textarea>
<br><input type="submit" value="<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"></form>
<?
}elseif(isset($_POST['id_bot'])) {
echo '<27><><EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>';
}
?>