Файл: 4wx.ru/sys/head.php
Строк: 59
<?
/*echo '<?xml version="1.0" encoding="utf-8"?>';*/
echo '
<!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.0//EN" "http://www.wapforum.org/DTD/xhtml-mobile10.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="ru">
<head>
<meta http-equiv="Content-Type" content="application/vnd.wap.xhtml+xml; charset=UTF-8" />
<meta name="description" content="'.output($set['description']).'" />
<meta name="keywords" content="'.output($set['keywords']).'" />
<link rel="shortcut icon" href="'.$HOME_S.'/style/img/favicon.ico" type="image/x-icon" />
<link rel="stylesheet" href="'.$HOME_S.'/style/wap.css" type="text/css" />
<link rel="stylesheet" href="'.$HOME_S.'/style/addition.css" type="text/css" />
<meta name="author" content="">
<meta name="copyright" content="">
<title>'.(isset($title) ? $title : $_SERVER['HTTP_HOST']).' </title>
</head>
<body>
<a href="/"><div class="head"><img src="'.$HOME_S.'/style/logo6.png" alt="Логотип"></div></a>';
$t = microtime(1);
if (!isset($_SESSION['user_id']))
{
echo '<div class="top_panel">
<table style="width: 100%"><tr>
<td style="width: 49%">
<a class="auth" href="/login">Вход</a>
</td>
<td style="width: 49%">
<a class="auth" href="/reg">Регистрация</a>
</td>
</tr>
</table>
</div>';
}
else
{
// Проверка на блокировку аккаунта
if ($user->blocking == 1)
{
echo $div->div_err.' Аккаунт заблокированый</div>';
exit;
}
$new_notice = mysql_num_rows(mysql_query("SELECT * FROM `system_notice` WHERE `id_user` = '$user->id' AND `chit` = '1'"));
$count = mysql_result(mysql_query("SELECT COUNT(*) FROM `mail` WHERE `user` = '$user->id' AND `read` = '0'"), 0);
?>
<div class="top_panel">
<table style="width: 100%"><tr>
<td style="width: 49%">
<a class="auth" href="/scripts/mail">Почта<?if($count>0)echo " <font color='red'>+$count</font>";?></a>
</td>
<td style="width: 49%">
<a class="auth" href="/scripts/user/cabinet">Кабинет</a>
</td>
</tr>
</table>
<?
if ($user->position == 'admin')
{
$t_new = mysql_result(mysql_query("SELECT COUNT(*) FROM `tickets` WHERE `closed` = '0' AND `read` = '0'"), 0);
if ($t_new > 0)echo " | <a class='auth' href='".$HOME."/scripts/tickets/admin_list.php?act=other'>Тикет <span class='count'>".$t_new."</span> </a>";
}
?></div><?
$IP = $_SERVER['REMOTE_ADDR'];
$browser = mysql_escape_string($_SERVER['HTTP_USER_AGENT']);
mysql_query("UPDATE `user` SET `time_last` = '". time() ."',`agent` = '". $browser ."', `IP` = '". $IP ."' WHERE `id` = '". $user->id ."' LIMIT 1");
}
?>