Файл: gonki.us/index.php
Строк: 104
<?php
require_once('system/incfiles/core.php');
if(isset($_GET['auto_benzin'])){
if($user['autobak'] == 0) $db->query('UPDATE `user` SET `autobak` = "1" WHERE `id` = "'.$user['id'].'"');
else $db->query('UPDATE `user` SET `autobak` = "0" WHERE `id` = "'.$user['id'].'"');
header('Location: /');
}
if (isset($_GET['exit']))
{
setcookie('uslogin', '', -1);
setcookie('uspassword', '', -1);
header('location: /');
}
if(empty($user)) header('Location: /auth.php');
$title = $copy.': Гараж';
require_once(ROOT.'system/incfiles/header.php');
echo '<div class="razd5">Гараж</div>';
if($user['auto'] == 0){
echo '<div class="menu_j"><a href="/magazin.php" class="top_menu_j"><img src="/system/design/img/ind.png" alt="*"/> Купить тачку!</a></div>
<div
class="garage"><br /><br /><br /><br /><center><img src="/auto/no_car.png" alt="no car" style="max-width:200px"/></center><br /><br /></div>';
}else{
echo '<div class="menu_j"><a class="top_menu_j" href="/my_auto.php"><span class="fl" style="margin-top:10px; margin-right:10px;"><span class="class">'.$usauto['class'].'</span><span class="name">'.$usauto['name'].'</span></span>
<br /><br /><center><img src="'.$usauto['img'].'" style="width:200px;" alt="" /> <img src="'.$usauto['neon'].'" alt="" style="width:200px; margin-top:-17px;"/></center></a></div>';
}
$c=$db->query('SELECT * FROM `mail_m` WHERE `komy` = "'.$user['id'].'" AND `open` = "1"')->num_rows;
if ($c > 0) $cc='<font colot="red">+'.$c.'</font>'; else $cc='';
echo '<table style="width:100%" cellspacing="0" cellpadding="0"><tr><td><center><div class="menu_j"><a href="/engine.php" class="top_menu_j"><img src="/system/design/ico/icoEngine.png" alt="" style="width:24px; height:24px;"/><br />Улучшить</a></div></center></td>
<td><center><div class="menu_j"><a href="/zadan.php" class="top_menu_j"><img src="/system/design/ico/zadan.png" alt="" style="width:24px; height:24px;"/><br />Задания</a></div></center></td>
<td><center><div class="menu_j"><a href="'.($ustaxi['taxi'] == NULL ? '/taxi.php' : '/taxi.php?act=view&id='.$ustaxi['taxi']).'" class="top_menu_j"><img src="/system/design/ico/concurents.png" alt="" style="width:24px; height:24px;"/><br />Такси</a></div></center></td>
<td><center><div class="menu_j"><a href="/turnir.php" class="top_menu_j"><img src="/system/design/ico/turnir.png" alt="" style="width:24px; height:24px;"/><br />Турнир</a></div></center></td>
</tr></table>
<div class="menu_j">
<a href="/?auto_benzin" class="top_menu_j">
<img src="auto/sm/mail.png" alt="" style="width:30px; height:auto"/> Бензин<span style="float:right">'.($user['autobak'] == 1 ? '<img src="/system/design/ico/on-btn.png" alt="" style="height:24px;"/>' : '<img src="/system/design/ico/off-btn.png" alt="" style="height:24px;"/>').'</span>
</a>
<a href="mail.php" class="top_menu_j"><img src="/auto/sm/tank.png" alt="*" style="width:30px; height:auto"/> Почта <span style="float:right">'.$cc.'</font></a></div>';
echo '<div class="razd4"><center><a href="?exit"><font color="#fff">Выход</font></a></center></div>';
require_once(ROOT.'system/incfiles/footer.php');
?>