Файл: impwar.tk/search.php
Строк: 80
<?php
require_once('conf/dbc.php');
require_once('conf/session_start.php');
if ((!isset($_SESSION['id'])) or(!isset($_SESSION['nick']))) { ?> <!--1390114136--> <script type="text/javascript">document.location.href ="login.php"</script> <?php exit(); }
$page_title = 'Поиск игрока';
require_once('conf/head.php');
require_once('conf/top.php');
echo '<br/><center><p class="name2">Поиск игрока</p></center>';
if ((!isset($_SESSION['id']))
and (!isset($_SESSION['nick']))) {header('location: /');}
$user_id = abs(intval($_SESSION['id']));
if(!isset($_POST['nick'])){
echo'<form action="?" method="post"><span class="bonus"><i><b>Введите ник игрока</i></b></span><br/><input type="text" name="nick" value=""/><br/><input type="submit" value="Поиск"/></form>';
}else{
$us=$dbc->query("SELECT `nick`,`id` ,`gruppa`, `lvl` FROM`users` WHERE`nick`='".$dbc->escape_string(htmlentities($_POST['nick'],ENT_QUOTES,'UTF-8'))."'")->fetch_assoc();
if ($us['gruppa'] == 'svoboda') {if ($razn_last_act < 300 ) {?><img src="img/ico/off.png" width="12" height="12" alt="н"/><img src="img/ico/svobodaon.png" width="12" height="12" alt="н"/><?php } else {?><img src="img/ico/on.png" width="12" height="12" alt="н"/><img src="img/ico/svobodaon.png" width="12" height="12" alt="н"/><?php }}
if ($us['gruppa'] == 'dolg') {if ($razn_last_act < 300 ) {?><img src="img/ico/off.png" width="12" height="12" alt="н"/><img src="img/ico/dolgon.png" width="12" height="12" alt="н"/><?php } else {?><img src="img/ico/on.png" width="12" height="12" alt="н"/><img src="img/ico/dolgon.png" width="12" height="12" alt="н"/><?php }}
if ($us['gruppa'] == 'naemniki') {if ($razn_last_act < 300 ) {?><img src="img/ico/off.png" width="12" height="12" alt="н"/><img src="img/ico/odinochkion.png" width="12" height="12" alt="н"/><?php } else {?><img src="img/ico/on.png" width="12" height="12" alt="н"/><img src="img/ico/odinochkion.png" width="12" height="12" alt="н"/><?php }}
if(strlen($us['nick'])>1){
echo'<a style="text-decoration:none;" href="profile.php?id='.$us['id'].'">'.$us['nick'].'</a><img src="img/ico/lvl.gif" width="15" height="15" alt="ур."/>'.$us['lvl'].'
<p class="zx"></p>
<a href="/search.php" class="menu" ><img src="img/reload.gif" width="15" height="15"/>Назад</a>';
unset($_POST['nick']);}else{echo'<span class="red">Пользователь не существуeт</span><p class="zx"></p><a href="/search.php" class="menu" ><img src="img/reload.gif" width="15" height="15"/>Назад</a>';}
}
require_once('conf/navig.php');
require_once('conf/foot.php');
mysqli_close($dbc);
?>
</body>
</html>