Файл: info.php
Строк: 780
<?
define('PROTECTOR', 1);
include('files/db.php');
include($path.'files/auth.php');
if ($user_id==0){
header('location: index.php');exit;
}
$_GET['id']=mysql_real_escape_string($_GET['id']);
$uss=mysql_num_rows(mysql_query("SELECT * FROM `users` WHERE `id`='".$_GET['id']."'"));
if($uss==0)
{
$g=1;
}
$us=mysql_fetch_array(mysql_query("SELECT * FROM `users` WHERE `id`='".$_GET['id']."'"));
$usy=mysql_fetch_array(mysql_query("SELECT * FROM `users_stats` WHERE `usr`='".$us['id']."'"));
$textl=$us['usr'];
include($path.'files/core.php');
if($g==1)
{
header('location: game.php');exit;
}
if(isset($_GET['fr']))
{
if($_GET['id']!=$udata['id'])
{
$usersfr=mysql_query("SELECT * FROM `friend` WHERE `usr2`='".$_GET['id']."' and `usr`='".$udata['id']."'");
$fr=mysql_num_rows($usersfr);
if($fr!=0)
{
header('location: ?id='.$_GET['id'].'');exit;
}
else
{
if($udata['kv_d']==22)
{
$kol=$udata['kv_d_n']+1;
mysql_query("UPDATE `users` SET `kv_d_n`='".$kol."' WHERE `id`='".$udata['id']."'");
}
mysql_query("INSERT INTO `friend` SET `id`='', `usr`='".$udata['id']."', `usr2`='".$_GET['id']."'");
header('location: ?id='.$_GET['id'].'');exit;
}
}
else
{
header('location: ?id='.$_GET['id'].'');exit;
}
}
if(isset($_GET['rr']))
{
$dd=date('d');
$dm=date('m');
if($dd>=8 and $dd<=11 and $dm==3 and $us['pol']==2)
{
if($udata['f8r']>0)
{
$rr=$us['f8r']+1;
$rt=$udata['f8r']-1;
mysql_query("UPDATE `users` SET `f8r`='".$rr."' WHERE `id`='".$us['id']."'");
$rows21=mysql_num_rows(mysql_query("SELECT * FROM `msg_kont` WHERE `usr1`='".$us['id']."' and `usr2`='0'"));
if($rows21==0)
{
mysql_query("INSERT INTO `msg_kont` SET
`id`='',
`usr1`='".$us['id']."',
`usr2`='0',
`read`='1',
`time`='".time()."'
");
}else
{
$rows2=mysql_fetch_array(mysql_query("SELECT * FROM `msg_kont`
WHERE `usr2`='0' and `usr1`='".$us['id']."'"));
mysql_query("UPDATE `msg_kont` SET `read`='1', `time`='".time()."' WHERE `usr2`='0' and `usr1`='".$us['id']."'");
}
$rows2=mysql_fetch_array(mysql_query("SELECT * FROM `msg_kont`
WHERE `usr2`='0' and `usr1`='".$us['id']."'"));
$text='Вы получили Красную Розу <img src=img/main/f8r.png>, от '.$udata['usr'].'';
mysql_query("INSERT INTO `msg_dialog` SET
`id`='',
`dialog`='".$rows2['id']."',
`vhod`='1',
`time`='".time()."',
`text`='".$text."',
`usr`='".$us['id']."'
");
mysql_query("UPDATE `users` SET `f8r`='".$rt."' WHERE `id`='".$udata['id']."'");
}
}
header('location: '.$_SERVER['HTTP_REFERER'].'');exit;
}
if(isset($_GET['md']))
{
if($udata['admin']>4 and $us['admin']<5)
{
mysql_query("UPDATE `users` SET `admin`='".mysql_real_escape_string($_POST['admin'])."' WHERE `id`='".$us['id']."'");
}
header('location: ?id='.$us['id'].'');exit;
}
if(isset($_GET['pay']))
{
if($udata['admin']==6)
{
$sum=mysql_real_escape_string($_POST['sum']);
if($sum!=0)
{
$p_p=mysql_fetch_array(mysql_query("SELECT * FROM `payments` ORDER BY `id` DESC"));
$in=$p_p['id']+1;
$v1=$us['id'];
mysql_query("insert into payments (id, invoice, v1, sum, payment_date, date_xsolla, status)
values ('$in','$in','$v1',$sum, now(), str_to_date('$date','%Y-%m-%d %T'),0)
");
}
}
header('location: ?id='.$us['id'].'');exit;
}
if(isset($_GET['gaika']))
{
if($udata['gaika']>0 and $us['pol']==1)
{
$g=$udata['gaika']-1;
$gr=$udata['reit_gaika']+1;
$gp=$us['gaika']+1;
mysql_query("UPDATE `users` SET `gaika`='".$gp."' WHERE `id`='".$us['id']."'");
mysql_query("UPDATE `users` SET `gaika`='".$g."', `reit_gaika`='".$gr."' WHERE `id`='".$udata['id']."'");
mysql_query("INSERT INTO `user_log` SET
`id`='',
`usr`='".$udata['id']."',
`text`='Шестерня подарена.'
");
$rows211=mysql_num_rows(mysql_query("SELECT * FROM `msg_kont` WHERE `usr1`='".$us['id']."' and `usr2`='0'"));
if($rows211==0)
{
mysql_query("INSERT INTO `msg_kont` SET
`id`='',
`usr1`='".$us['id']."',
`usr2`='0',
`read`='1',
`time`='".time()."'
");
}else
{
$rows21=mysql_fetch_array(mysql_query("SELECT * FROM `msg_kont`
WHERE `usr2`='0' and `usr1`='".$us['id']."'"));
mysql_query("UPDATE `msg_kont` SET `read`='1', `time`='".time()."' WHERE `usr2`='0' and `usr1`='".$us['id']."'");
}
$rows21=mysql_fetch_array(mysql_query("SELECT * FROM `msg_kont`
WHERE `usr2`='0' and `usr1`='".$us['id']."'"));
$text='<font color=#cccccc>Вы получили Шестерню от '.$udata['usr'].'.</font>
';
mysql_query("INSERT INTO `msg_dialog` SET
`id`='',
`dialog`='".$rows21['id']."',
`vhod`='1',
`time`='".time()."',
`text`='".$text."',
`usr`='".$us['id']."'
");
}
header('location: ?id='.$us['id'].'');exit;
}
include($path.'files/head.php');
include($path.'files/zag.php');
echo '<table width=100%>
<tr>
<td width=35%>
<a href=game.php><div style="background: #882222; border-radius: 7px 0 0 7px" class="m p bts bbs brs bls" align=center>Главная</div></a>
</td><td>';
echo '<a href=?id='.$us['id'].'><div class="line bts brs bls bbs p m" style="border-radius: 0 7px 7px 0">
<font color=#ffffff>Персонаж
</font>
</div></a></td></tr></table>';
echo '<div class="bat bts brs bls bbs p">';
$tit=mysql_query("SELECT * FROM `titul` WHERE `usr`='".$us['id']."' and `status`='1'");
$n_tit=mysql_num_rows($tit);
if($n_tit==0)
{
echo '[<a href=titl.php>Новичек</a>] ';
}
else
{
$tt=mysql_fetch_array($tit);
echo '[<img src=img/arena_rang/'.$tt['img'].'.png><a href=titl.php><font color=#ff9900><i>'.$tt['name'].'</i></font></a>] ';
}
if($us['admin']>0 and $us['admin']<6)
{
echo '<img src=img/main/md.png> ';
}
elseif($us['admin']>5)
{
echo '<img src=img/main/admin.png> ';
}
echo '<img src=img/main/c'.$us['klass'].'.png> <img src=img/main/r'.$us['rasa'].'.png> ';
echo '<a href=info.php?id='.$us['id'].'>'.$us['usr'].'</a> <img src=img/main/p10.png>'.$us['lvl'].'<br>';
echo '
<table>
<tr>
<td>';
if($us['ava']==0)
{
echo'<img src=img/pers/'.$us['klass'].''.$us['pol'].'.png>
';
}
else
{
echo'<img src=img/pers/ava/'.$us['ava'].'.png>';
}
echo'</td>
<td>';
if($us['rang']==0)
{
}
else
{
echo'<img src=img/rang/'.$us['rang'].'.png>';
}
echo'</td>
</tr>
</table>
';
if($udata['admin']>=5 and $us['admin']<5)
{
echo '<form action=?id='.$us['id'].'&md method=POST>';
echo '<b>Права</b><br><select name=admin>
<option value=0>Игрок</option>
<option value=2>Мд чата</option>
<option value=3>Мд форума</option>
<option value=4>Старший мд</option>
';
echo'</select><input type=submit value=Назначить class=line></form><br>';
}
if($udata['admin']>0)
{
echo'<a href=?id='.$us['id'].'&ban><font color=#ff0000>Наказать</font></a><br>';
if(isset($_GET['ban']))
{
echo'</div><div class="v3 bts brs bls b p v12">Бан</div><div class="v2 bts brs bls bbs p t1">';
echo'Тип бана:<br>';
if($udata['admin']!=3)
{
echo'<a href=?id='.$us['id'].'&ban&chat><font color=#ff0000>Бан Чата</font></a> | ';
}
if($udata['admin']!=2)
{
echo'<a href=?id='.$us['id'].'&ban&forum><font color=#ff0000>Бан Форума</font></a> | ';
}
if($udata['admin']>3)
{
echo'<a href=?id='.$us['id'].'&ban&mail><font color=#ff0000>Бан Почты</font></a> | ';
}
if($udata['admin']>4)
{
echo'<a href=?id='.$us['id'].'&ban&blok><font color=#ff0000>Блок</font></a>';
}
echo'<br>';
if(isset($_GET['chat']))
{
if($udata['admin']!=3)
{
echo '<form action="ban.php?id='.$us['id'].'&chat" method=POST>';
echo 'БАН Чата:<br>';
echo 'Время:<br>';
echo '
<select name=time>
<option value=30>30 минут</option>
<option value=60>1 час</option>
<option value=180>3 часа</option>
<option value=360>6 часов</option>
<option value=720>12 часов</option>
<option value=1440>сутки</option>';
if($udata['admin']>3)
{
echo '<option value=2880>2 дня</option>
<option value=4320>3 дня</option>
<option value=10080>7 дней</option>
';
}
echo'
</select><br>
Причина:<br>
<textarea name="text" rows="3"></textarea>
<br><input type=submit value=Наказать class=line></form>
';
echo '</form>';
}
}
if(isset($_GET['forum']))
{
if($udata['admin']!=2)
{
echo '<form action="ban.php?id='.$us['id'].'&forum" method=POST>';
echo 'БАН Форума:<br>';
echo 'Время:<br>';
echo '
<select name=time>
<option value=30>30 минут</option>
<option value=60>1 час</option>
<option value=180>3 часа</option>
<option value=360>6 часов</option>
<option value=720>12 часов</option>
<option value=1440>сутки</option>';
if($udata['admin']>3)
{
echo '<option value=2880>2 дня</option>
<option value=4320>3 дня</option>
<option value=10080>7 дней</option>
';
}
echo'
</select><br>
Причина:<br>
<textarea name="text" rows="3"></textarea>
<br><input type=submit value=Наказать class=line></form>
';
echo '</form>';
}}
if(isset($_GET['mail']))
{
if($udata['admin']>3)
{
echo '<form action="ban.php?id='.$us['id'].'&msg" method=POST>';
echo 'БАН Почты:<br>';
echo 'Время:<br>';
echo '
<select name=time>
<option value=30>30 минут</option>
<option value=60>1 час</option>
<option value=180>3 часа</option>
<option value=360>6 часов</option>
<option value=720>12 часов</option>
<option value=1440>сутки</option>';
echo '<option value=2880>2 дня</option>
<option value=4320>3 дня</option>
<option value=10080>7 дней</option>
<option value=20080>14 дней</option>
<option value=43200>30 дней</option>
<option value=86400>60 дней</option>
<option value=144000>100 дней</option>
';
}
echo'
</select><br>
Причина:<br>
<textarea name="text" rows="3"></textarea>
<br><input type=submit value=Наказать class=line></form>
';
echo '</form>';
}
if(isset($_GET['blok']))
{
if($udata['admin']>4)
{
echo '<form action="ban.php?id='.$us['id'].'&boi" method=POST>';
echo 'БЛОК:<br>';
echo 'Время:<br>';
echo '
<select name=time>
<option value=30>30 минут</option>
<option value=60>1 час</option>
<option value=180>3 часа</option>
<option value=360>6 часов</option>
<option value=720>12 часов</option>
<option value=1440>сутки</option><option value=2880>2 дня</option>
<option value=4320>3 дня</option>
<option value=10080>7 дней</option>
<option value=20080>14 дней</option>
<option value=43200>30 дней</option>';
echo '
<option value=86400>60 дней</option>
<option value=144000>100 дней</option>
<option value=288000>200 дней</option>
';
echo'
</select><br>
Причина:<br>
<textarea name="text" rows="3"></textarea>
<br><input type=submit value=Наказать class=line></form>
';
echo '</form>';
}
}
echo'</div><div class="v2 bts brs bls bbs p t1">';
}
}
$bans = mysql_query("SELECT * FROM `ban` WHERE `usr` = '".$us['id']."'");
$banq=mysql_num_rows($bans);
if($banq!=0)
{
echo '</div><div class="v2 bts brs bls bbs p t1">';
while($ban=mysql_fetch_array($bans))
{
if($ban['place']==1)
{
echo '<font color=#00ffff>Бан Чата</font> <br>Времени осталось: <font color=#ff0000>';
}
if($ban['place']==2)
{
echo '<font color=#00ffff>Бан Форума</font> <br>Времени осталось: <font color=#ff0000>';
}
if($ban['place']==3)
{
echo '<font color=#00ffff>Бан Почты</font> <br>Времени осталось: <font color=#ff0000>';
}
if($ban['place']==4)
{
echo '<font color=#00ffff>Персонаж Заблокирован</font> <br>Времени осталось: <font color=#ff0000>';
}$usq = mysql_query("SELECT * FROM `users` WHERE `id` = '".$ban['md']."'");
$usb=mysql_fetch_array($usq);
if($ban['time']==0)
{
echo '</font>';
}
else
{
$ban['time']=$ban['time']-time();
if($ban['time']<60){
echo $ban['time']." сек.</font>";
}elseif($ban['time']>60 and $ban['time']<3600){
$ban['time']=round($ban['time']/60);
echo $ban['time']." мин.</font>";
}else{
$ban['time']=round($ban['time']/3600);
echo $ban['time']." часов</font>";
}
}
echo'</font>';
if($usb['admin']>0 and $usb['admin']<5)
{
$img='<img src=img/main/md.png>';
}
if($usb['admin']>5)
{
$img='<img src=img/main/admin.png>';
}
echo' '.$img.'<a href=info.php?id='.$ban['md'].'>
<img src=img/main/c'.$usb['klass'].'.png> <img src=img/main/r'.$usb['rasa'].'.png> '.$usb['usr'].'</a>
<img src=img/main/p10.png alt=lvl>'.$usb['lvl'].'
<br>';
echo 'Причина: <font color=#ff0000>'.$ban['text'].'</font><br>';
if($udata['admin']>3)
{
echo'[<a href=ban.php?sh&id='.$ban['id'].'>снять</a>]<br>';
}
}
echo '</div><div class="v2 bts brs bls bbs p t1">';
}
echo '<img src=img/main/p23.png> <font color=#999999>Звание:</font> ';
$rang=mysql_fetch_array(mysql_query("SELECT * FROM `rang` WHERE `rang`='".$us['rang']."'"));
echo ''.$rang['name'].' (<img src=img/main/p36.png> '.$us['rang'].')<br>';
echo '<img src=img/main/r'.$us['rasa'].'.png> Раса: ';
if($us['rasa']==1)
{
echo '<font color=#009900>Кания</font><br>';
}
if($us['rasa']==2)
{
echo '<font color=#ff0000>Хадаган</font><br>';
}
if($us['clan']==0)
{
}
else
{
echo '<img src=img/main/p15.png> Гильдия: ';
$mobs=mysql_query("SELECT * FROM `clan` WHERE `id`='".$us['clan']."'");
$avto=mysql_fetch_array($mobs);
echo ' <a href=clans.php?id='.$avto['id'].'>'.$avto['name'].'</a> <img src=img/main/p10.png>'.$avto['lvl'].'<br>';
}
if($us['admin']>0)
{
echo '<img src=img/main/md.png> <font color=#00ff00>Должность:</font> ';
if($us['admin']==1)
{
echo 'стражер';
}
if($us['admin']==2)
{
echo 'мд чата';
}
if($us['admin']==3)
{
echo 'мд форума';
}
if($us['admin']==4)
{
echo 'старший мд';
}
if($us['admin']==5)
{
echo 'верховный мд';
}
if($us['admin']==6)
{
echo 'системный администратор';
}
}
echo '<br><br>';
echo '<img src=img/main/e1.png> <a href=mail.php?dialog&id='.$us['id'].'>Написать письмо</a><br>';
$qwes=mysql_query("SELECT * FROM `friend` WHERE `usr`='".$udata['id']."' and `usr2`='".$us['id']."'");
$qwe=mysql_num_rows($qwes);
if($qwe!=0)
{
$qwea=mysql_fetch_array($qwes);
echo '<img src=img/main/e2.png> Это ваш друг!<br>';
}
else
{
if($us['id']!=$udata['id'])
{
echo '<img src=img/main/e2.png> <a href=?fr&id='.$us['id'].'>Добавить в друзья!</a><br>';
}
}
echo '<img src=img/main/e16.png> <a href=inv_us.php?id='.$us['id'].'>Амуниция</a><br>';
echo '</div></div><div class="v8">';
echo '<div class="line m bbs bts brs bls b p v12">Характеристики</div>';
echo '<div class="bat bts brs bls bbs p t3">';
echo '<img src=img/main/p3.png> <font color=#999999>Здоровье:</font> <font color=#ff0000>'.$usy['hp_max'].'</font><br>';
echo '<img src=img/main/p1.png> <font color=#999999>Урон:</font> <font color=#ff0000>'.$usy['sila'].'</font><br>';
echo '<img src=img/main/p2.png> <font color=#999999>Броня:</font> <font color=#ff0000>'.$usy['arm'].'</font><br>';
echo '<img src=img/main/b2.png> <font color=#999999>Шанс крита:</font> <font color=#00ff00>'.$usy['krit'].'%</font><br>';
echo '<img src=img/main/b23.png> <font color=#999999>Шанс блока:</font> <font color=#00ff00>'.$usy['blok'].'%</font><br>';
$st_zvu=mysql_result(mysql_query("SELECT SUM(zvezd) FROM `item` WHERE `status`='on' and `usr`='".$us['id']."'"),0);
if($st_zvu<5){$szs=0;}
elseif($st_zvu>=5 and $st_zvu<10)
{
$szs=5;
}
elseif($st_zvu>=10 and $st_zvu<15)
{
$szs=10;
}
elseif($st_zvu>=15 and $st_zvu<20)
{
$szs=15;
}
elseif($st_zvu>=20 and $st_zvu<25)
{
$szs=20;
}
elseif($st_zvu>=25 and $st_zvu<30)
{
$szs=25;
}
elseif($st_zvu>=30)
{
$szs=30;
}
echo '<img src=img/main/p7.png> <font color=#999999>Сила звезд:</font> <font color=#00ff00>'.$st_zvu.'</font> (+'.$szs.'%)</br>';
$ss=$usy['hp1']+$us['sila1']+$us['arm1'];
echo '<img src=img/main/p7.png> <font color=#999999>Сумма статов:</font> <font color=#00ff00>'.$us['stats'].'</font></br>';
$bon1=mysql_num_rows(mysql_query("SELECT * FROM `item` WHERE `usr`='".$us['id']."' and `status`='on' and `tip`='knyt'"));
if($bon1!=0){
$bon1f=mysql_fetch_array(mysql_query("SELECT * FROM `item` WHERE `usr`='".$us['id']."' and `status`='on' and `tip`='knyt'"));
echo '<img src=img/main/e28.png> Бонус: '.$bon1f['name'].'<br>';
}
$bon2=mysql_num_rows(mysql_query("SELECT * FROM `item` WHERE `usr`='".$us['id']."' and `status`='on' and `tip`='knyt2'"));
if($bon2!=0){
$bon2f=mysql_fetch_array(mysql_query("SELECT * FROM `item` WHERE `usr`='".$us['id']."' and `status`='on' and `tip`='knyt2'"));
echo '<img src=img/main/e28.png> Бонус: '.$bon2f['name'].'<br>';
}
$bon3=mysql_num_rows(mysql_query("SELECT * FROM `item` WHERE `usr`='".$us['id']."' and `status`='on' and `tip`='kyvshin'"));
if($bon3!=0){
$bon3f=mysql_fetch_array(mysql_query("SELECT * FROM `item` WHERE `usr`='".$us['id']."' and `status`='on' and `tip`='kyvshin'"));
echo '<img src=img/main/e28.png> Бонус: '.$bon3f['name'].'<br>';
}
$bon4=mysql_num_rows(mysql_query("SELECT * FROM `item` WHERE `usr`='".$us['id']."' and `status`='on' and `tip`='best'"));
if($bon4!=0){
$bon4f=mysql_fetch_array(mysql_query("SELECT * FROM `item` WHERE `usr`='".$us['id']."' and `status`='on' and `tip`='best'"));
echo '<img src=img/main/e28.png> Бонус: '.$bon4f['name'].'<br>';
}
$bon5=mysql_num_rows(mysql_query("SELECT * FROM `item` WHERE `usr`='".$us['id']."' and `status`='on' and `tip`='best2'"));
if($bon5!=0){
$bon5f=mysql_fetch_array(mysql_query("SELECT * FROM `item` WHERE `usr`='".$us['id']."' and `status`='on' and `tip`='best2'"));
echo '<img src=img/main/e28.png> Бонус: '.$bon5f['name'].'<br>';
}
$bon6=mysql_num_rows(mysql_query("SELECT * FROM `item` WHERE `usr`='".$us['id']."' and `status`='on' and `tip`='poas'"));
if($bon6!=0){
$bon6f=mysql_fetch_array(mysql_query("SELECT * FROM `item` WHERE `usr`='".$us['id']."' and `status`='on' and `tip`='poas'"));
echo '<img src=img/main/e28.png> Бонус: '.$bon6f['name'].'<br>';
}
$bon7=mysql_num_rows(mysql_query("SELECT * FROM `item` WHERE `usr`='".$us['id']."' and `status`='on' and `tip`='poas2'"));
if($bon7!=0){
$bon7f=mysql_fetch_array(mysql_query("SELECT * FROM `item` WHERE `usr`='".$us['id']."' and `status`='on' and `tip`='poas2'"));
echo '<img src=img/main/e28.png> Бонус: '.$bon7f['name'].'<br>';
}
if($udata['admin']==6)
{
echo '<form action=?pay&id='.$us['id'].' method=POST>
<input type=text name=sum size=5><input type=submit value="Далее">
</form>';
}
echo'</div></div><div class="v8">';
echo '<div class="line bbs m bts brs bls b p v12">Статистика</div>';
echo '<div class="bat bts brs bls bbs p t3">';
echo'<img src=img/main/e55.png> Пол: ';
if($us['pol']==1)
{
echo'Мужчина<br>';
}
else
{
echo'Женщина<br>';
}
echo'<img src=img/main/e55.png> Регистрация: '.$us['reg'].'<br>';
echo'<img src=img/main/e55.png> Последний визит: '.$us['last'].'<br>';
echo'<img src=img/main/e55.png> Место: '.$us['mesto'].'<br>';
if($udata['admin']==5 and $us['admin']!=6 or $udata['admin']==6)
{
if(isset($_GET['info']))
{
echo'<div class="v5 p">';
if(isset($_GET['ipv4']))
{
$id=mysql_real_escape_string($_GET['ipv4']);
$global_info=mysql_query("SELECT * FROM `global_info` WHERE `usr`='".$us['id']."' and `id`='".$id."'");
$gl=mysql_fetch_array($global_info);
echo 'IPv4: '.$gl['ipv4'].'<br>';
$gf=mysql_query("SELECT * FROM `global_info` WHERE `usr`!='".$us['id']."' and `ipv4`='".$gl['ipv4']."' GROUP BY `usr`");
while($gg=mysql_fetch_array($gf))
{
$usr=mysql_query("SELECT * FROM `users` WHERE `id`='".$gg['usr']."'");
$user=mysql_fetch_array($usr);
if($user['admin']>0 and $user['admin']<5)
{
$imgs='<img src=img/main/md.png>';
}
if($user['admin']>5)
{
$imgs='<img src=img/main/admin.png>';
}else
{
$imgs='';
}
echo' '.$imgs.'<a href=info.php?id='.$user['id'].'>
<img src=img/main/c'.$user['klass'].'.png> <img src=img/main/r'.$user['rasa'].'.png> '.$user['usr'].'</a>
<img src=img/main/p10.png alt=lvl>'.$user['lvl'].'
<br>';
}
echo '<br><a href=?id='.$us['id'].'&info>Назад</a>';
}
elseif(isset($_GET['ipv6']))
{
$id=mysql_real_escape_string($_GET['ipv6']);
$global_info=mysql_query("SELECT * FROM `global_info` WHERE `usr`='".$us['id']."' and `id`='".$id."'");
$gl=mysql_fetch_array($global_info);
echo 'IPv6: '.$gl['ipv6'].'<br>';
$gf=mysql_query("SELECT * FROM `global_info` WHERE `usr`!='".$us['id']."' and `ipv6`='".$gl['ipv6']."' GROUP BY `usr`");
while($gg=mysql_fetch_array($gf))
{
$usr=mysql_query("SELECT * FROM `users` WHERE `id`='".$gg['usr']."'");
$user=mysql_fetch_array($usr);
if($user['admin']>0 and $user['admin']<5)
{
$imgs='<img src=img/main/md.png>';
}
if($user['admin']>5)
{
$imgs='<img src=img/main/admin.png>';
}
else
{
$imgs='';
}
echo' '.$imgs.'<a href=info.php?id='.$user['id'].'>
<img src=img/main/c'.$user['klass'].'.png> <img src=img/main/r'.$user['rasa'].'.png> '.$user['usr'].'</a>
<img src=img/main/p10.png alt=lvl>'.$user['lvl'].'
<br>';
}
echo '<br><a href=?id='.$us['id'].'&info>Назад</a>';
}
elseif(isset($_GET['host']))
{
$id=mysql_real_escape_string($_GET['host']);
$global_info=mysql_query("SELECT * FROM `global_info` WHERE `usr`='".$us['id']."' and `id`='".$id."'");
$gl=mysql_fetch_array($global_info);
echo 'Host: '.$gl['host'].'<br>';
$gf=mysql_query("SELECT * FROM `global_info` WHERE `usr`!='".$us['id']."' and `host`='".$gl['host']."' GROUP BY `usr`");
while($gg=mysql_fetch_array($gf))
{
$usr=mysql_query("SELECT * FROM `users` WHERE `id`='".$gg['usr']."'");
$user=mysql_fetch_array($usr);
if($user['admin']>0 and $user['admin']<5)
{
$imgs='<img src=img/main/md.png>';
}
if($user['admin']>5)
{
$imgs='<img src=img/main/admin.png>';
}
echo' '.$imgs.'<a href=info.php?id='.$user['id'].'>
<img src=img/main/c'.$user['klass'].'.png> <img src=img/main/r'.$user['rasa'].'.png> '.$user['usr'].'</a>
<img src=img/main/p10.png alt=lvl>'.$user['lvl'].'
<br>';
}
echo '<br><a href=?id='.$us['id'].'&info>Назад</a>';
}
elseif(isset($_GET['br']))
{
$id=mysql_real_escape_string($_GET['br']);
$global_info=mysql_query("SELECT * FROM `global_info` WHERE `usr`='".$us['id']."' and `id`='".$id."'");
$gl=mysql_fetch_array($global_info);
echo 'Brouser: '.$gl['br'].' '.$gl['br_vers'].'<br>';
$gf=mysql_query("SELECT * FROM `global_info` WHERE `usr`!='".$us['id']."' and `br`='".$gl['br']."' and `br_vers`='".$gl['br_vers']."' GROUP BY `usr`");
while($gg=mysql_fetch_array($gf))
{
$usr=mysql_query("SELECT * FROM `users` WHERE `id`='".$gg['usr']."'");
$user=mysql_fetch_array($usr);
if($user['admin']>0 and $user['admin']<5)
{
$imgs='<img src=img/main/md.png>';
}
if($user['admin']>5)
{
$imgs='<img src=img/main/admin.png>';
}else
{
$imgs='';
}
echo' '.$imgs.'<a href=info.php?id='.$user['id'].'>
<img src=img/main/c'.$user['klass'].'.png> <img src=img/main/r'.$user['rasa'].'.png> '.$user['usr'].'</a>
<img src=img/main/p10.png alt=lvl>'.$user['lvl'].'
<br>';
}
echo '<br><a href=?id='.$us['id'].'&info>Назад</a>';
}
elseif(isset($_GET['os']))
{
$id=mysql_real_escape_string($_GET['os']);
$global_info=mysql_query("SELECT * FROM `global_info` WHERE `usr`='".$us['id']."' and `id`='".$id."'");
$gl=mysql_fetch_array($global_info);
echo 'OS: '.$gl['os'].' '.$gl['os_vers'].'<br>';
$gf=mysql_query("SELECT * FROM `global_info` WHERE `usr`!='".$us['id']."' and `os`='".$gl['os']."' and `os_vers`='".$gl['os_vers']."' GROUP BY `usr`");
while($gg=mysql_fetch_array($gf))
{
$usr=mysql_query("SELECT * FROM `users` WHERE `id`='".$gg['usr']."'");
$user=mysql_fetch_array($usr);
if($user['admin']>0 and $user['admin']<5)
{
$imgs='<img src=img/main/md.png>';
}
if($user['admin']>5)
{
$imgs='<img src=img/main/admin.png>';
}else
{
$imgs='';
}
echo' '.$imgs.'<a href=info.php?id='.$user['id'].'>
<img src=img/main/c'.$user['klass'].'.png> <img src=img/main/r'.$user['rasa'].'.png> '.$user['usr'].'</a>
<img src=img/main/p10.png alt=lvl>'.$user['lvl'].'
<br>';
}
echo '<br><a href=?id='.$us['id'].'&info>Назад</a>';
}
else
{
echo '<font color=#ffff00>Сейчас:</font><br>';
echo '<table width=100% class="box p">';
echo '<tr><td colspan=1>';
echo 'IPv4:</td><td colspan=1> '.$us['ipv4'].'<br>';
echo '</tr></td>';
echo '<tr><td>';
echo 'IPv6:</td><td> '.$us['ipv6'].'<br>';
echo '</tr></td>';
echo '<tr><td>';
echo 'Host:</td><td> '.$us['host'].'<br>';
echo '</tr></td>';
echo '<tr><td>';
echo 'Conect:</td><td> '.$us['con'].'<br>';
echo '</tr></td>';
echo '<tr><td>';
echo 'Браузер:</td><td> '.$us['br'].' '.$us['br_vers'].'<br>';
echo '</tr></td>';
echo '<tr><td>';
echo 'ОС:</td><td> '.$us['os'].' '.$us['os_vers'].'<br>';
echo '</tr></td>';
echo '<tr><td>';
echo 'разр. экрана:</td><td> '.$us['screen'].'<br>';
echo '</tr></td>';
echo '<tr><td>';
echo 'разр. окна браузера:</td><td> '.$us['screen_br'].'<br>';
echo '</tr></td>';
echo '<tr><td>';
echo 'исходник:</td><td> '.$us['gl'].'<br>';
echo '</tr></td>';
echo '</table>';
echo '<font color=#ffff00>5 последних записей:</font><br>';
$global_info=mysql_query("SELECT * FROM `global_info` WHERE `usr`='".$us['id']."' ORDER BY `id` DESC LIMIT 5");
while($gl=mysql_fetch_array($global_info))
{
echo '<small><table width=100% class="box m bts bbs brs bls p" border=1px>';
echo '<tr><td colspan=1>';
echo 'IPv4:</td><td colspan=1> '.$gl['ipv4'].'<br>';
echo '</td><td colspan=1>';
$global_ipv4=mysql_num_rows(mysql_query("SELECT * FROM `global_info` WHERE `usr`!='".$us['id']."' and `ipv4`='".$gl['ipv4']."' GROUP BY `usr`"));
echo '<a href=?id='.$us['id'].'&info&ipv4='.$gl['id'].'><font color=#ff9900>'.$global_ipv4.'</font></a><br>';
echo'</td>';
echo '</tr></td>';
echo '<tr><td>';
echo 'IPv6:</td><td> '.$gl['ipv6'].'<br>';
echo '</td><td>';
if($gl['apv6']!='')
{
$global_ipv6=mysql_num_rows(mysql_query("SELECT * FROM `global_info` WHERE `usr`!='".$us['id']."' and `ipv6`='".$gl['ipv6']."' GROUP BY `usr`"));
echo '<a href=?id='.$us['id'].'&info&ipv6='.$gl['id'].'><font color=#ff9900>'.$global_ipv6.'</font></a><br>';
}else {echo '<font color=#ff9900>0</font>';}
echo'</td>';
echo '</tr></td>';
echo '<tr><td>';
echo 'Host:</td><td> '.$gl['host'].'<br>';
echo '</td><td>';
if($gl['host']!='')
{
$global_host=mysql_num_rows(mysql_query("SELECT * FROM `global_info` WHERE `usr`!='".$us['id']."' and `host`='".$gl['host']."' GROUP BY `usr`"));
echo '<a href=?id='.$us['id'].'&info&host='.$gl['id'].'><font color=#ff9900>'.$global_host.'</font></a><br>';
}else {echo '<font color=#ff9900>0</font>';}
echo'</td>';
echo '</tr></td>';
echo '<tr><td>';
echo 'Conect:</td><td> '.$gl['con'].'<br>';
echo '</td><td>';
echo'</td>';
echo '</tr></td>';
echo '<tr><td>';
echo 'Браузер:</td><td> '.$gl['br'].' '.$gl['br_vers'].'<br>';
echo '</td><td>';
if($gl['br']!='')
{
$global_br=mysql_num_rows(mysql_query("SELECT * FROM `global_info` WHERE `usr`!='".$us['id']."' and `br`='".$gl['br']."' and `br_vers`='".$gl['br_vers']."' GROUP BY `usr`"));
echo '<a href=?id='.$us['id'].'&info&br='.$gl['id'].'><font color=#ff9900>'.$global_br.'</font></a><br>';
}else {echo '<font color=#ff9900>0</font>';}
echo'</td>';
echo '</tr></td>';
echo '<tr><td>';
echo 'ОС:</td><td> '.$gl['os'].' '.$gl['os_vers'].'<br>';
echo '</td><td>';
if($gl['os']!='')
{
$global_os=mysql_num_rows(mysql_query("SELECT * FROM `global_info` WHERE `usr`!='".$us['id']."' and `os`='".$gl['os']."' and `os_vers`='".$gl['os_vers']."' GROUP BY `usr`"));
echo '<a href=?id='.$us['id'].'&info&os='.$gl['id'].'><font color=#ff9900>'.$global_os.'</font></a><br>';
}else {echo '<font color=#ff9900>0</font>';}
echo'</td>';
echo '</tr></td>';
echo '<tr><td>';
echo 'разр. экрана:</td><td> '.$gl['screen'].'<br>';
echo '</td><td>';
if($gl['screen']!='')
{
$global_screen=mysql_num_rows(mysql_query("SELECT * FROM `global_info` WHERE `usr`!='".$us['id']."' and `screen`='".$gl['screen']."' GROUP BY `usr`"));
echo '<a href=?id='.$us['id'].'&info&screen='.$gl['id'].'><font color=#ff9900>'.$global_screen.'</font></a><br>';
}else {echo '<font color=#ff9900>0</font>';}
echo'</td>';
echo '</tr></td>';
echo '<tr><td>';
echo 'разр. окна браузера:</td><td> '.$gl['screen_br'].'<br>';
echo '</td><td>';
if($gl['screen_br']!='')
{
$global_screen_br=mysql_num_rows(mysql_query("SELECT * FROM `global_info` WHERE `usr`!='".$us['id']."' and `screen_br`='".$gl['screen_br']."' GROUP BY `usr`"));
echo '<a href=?id='.$us['id'].'&info&screen_br='.$gl['id'].'><font color=#ff9900>'.$global_screen_br.'</font></a><br>';
}else {echo '<font color=#ff9900>0</font>';}
echo'</td>';
echo '</tr></td>';
echo '<tr><td>';
echo 'Дата:</td><td> '.$gl['data'].'<br>';
echo '</tr></td>';
echo '<tr><td>';
echo 'Исходник:</td><td> '.$gl['gl'].'<br>';
echo '</tr></td>';
echo '</table></small>';
}
}
echo'</div>';
}
else
{
echo'<div class="v5 p"><a href=?id='.$us['id'].'&info>Открыть информацию</a></div>';
}
}
$gid=mysql_query("SELECT * FROM `gift` WHERE `usr`='".$us['id']."'");
$gf=mysql_num_rows($gid);
if($gf!=0)
{
echo '</div></div><div class="v8">';
echo '<div class="line m bbs bts brs bls b p v12">Подарки</div>';
echo '<div class="bat bts brs bls bbs p t1">';
$frid=mysql_query("SELECT * FROM `gift` WHERE `usr`='".$us['id']."'");
while($fr=mysql_fetch_array($frid))
{
echo '<img src=img/gift/'.$fr['gift'].'.png> ';
}
}
$baf_s=mysql_query("SELECT * FROM `item` WHERE `usr`='".$us['id']."' and `name`=''");
$bs=mysql_num_rows($baf_s);
if($bs!=0)
{
echo '</div></div><div class="v8">';
echo '<div class="line m bbs bts brs bls b p v12">Усиления</div>';
echo '<div class="bat bts brs bls bbs p t1">';
while($bf=mysql_fetch_array($baf_s))
{
echo '<img src=img/baf/b'.$bf['img'].'.png> ';
}
}
echo '</div></div>';
include('files/down.php');
?>