<?php
/*Онлайн игра Football Manager под DCMS версии 6.6.4

 *ВНИМАНИЕ!!! Данный скрипт нельзя распространять, нельзя продавать, менять и т.д.

 *Автор скрипта: Doctor

 *Тех поддержка: 

 *icq: 624552318

 *e-mail: dudringvala@yahoo.com

 *skype: isevgio

 */
include_once '../sys/inc/start.php';
include_once '../sys/inc/compress.php';
include_once '../sys/inc/sess.php';
include_once '../sys/inc/home.php';
include_once '../sys/inc/settings.php';
include_once '../sys/inc/db_connect.php';
include_once '../sys/inc/ipua.php';
include_once '../sys/inc/fnc.php';
include_once '../sys/inc/user.php';
$set['title']='Футбольный менеджер';
include_once '../sys/inc/thead.php';
title();
err();
aut();

include_once 'online.php';
echo "<div class='frends2'>";
echo'<img src="icon/wap_main.png" width="140" height="70" alt="Karson" />';
//echo "<small>Онлайн: ";
//$onl = mysql_result(mysql_query("SELECT COUNT(*) FROM `fm_who`"), 0);
//if ($onl==0)echo 'Никто...';
//$sql = mysql_query("SELECT `id_user` FROM `fm_who`");
//while($us = mysql_fetch_assoc($sql))
//{
//$login=mysql_fetch_array(mysql_query("select `nick` from `user` where `id`='".$us['id_user']."' limit 1;"));
//echo "<a href='club.php?id=".$us['id_user']."'>$login[nick]</a>,\n";
//}
//echo "</small>";

echo "</div>";
$cena = mysql_fetch_array(mysql_query("SELECT * FROM `fm_admin` WHERE `id` = '1' LIMIT 1"));
$chempionat= mysql_result(mysql_query("SELECT COUNT(*) FROM `fm_chempionat`",$db), 0); 
$chempionatnew = mysql_result(mysql_query("SELECT COUNT(*) FROM `fm_chempionat` WHERE `time` > '".(time()-86400)."'"), 0);
echo "<div class='frends2'><img src='icon/m.gif'> <a href='chempionat/index.php'>Чемпионаты</a>\n";
if ($chempionatnew>0){echo "($chempionat)<span style='color:red'>+$chempionatnew</span><br />";}else{echo "($chempionat)<br />";} echo'</div>';
$movlenebi = mysql_result(mysql_query("SELECT COUNT(*) FROM `fm_jurnal` WHERE `id_user` = '$user[id]'"), 0);
$axalimovlenebi =mysql_result(mysql_query("SELECT COUNT(*) FROM `fm_jurnal` WHERE `id_user` = '$user[id]' AND `read` = '0'"), 0);
echo "<div class='frends'><img src='icon/m.gif'> <a href='jurnal.php'>События</a>\n";
if($axalimovlenebi>0){echo "($movlenebi)<span style='color:#FF0000'>+$axalimovlenebi</span><br/>";}else{echo "($movlenebi)<br/>";} echo'</div>';
$ist= mysql_result(mysql_query("SELECT COUNT(*) FROM `fm_ist`",$db), 0);
$istnew = mysql_result(mysql_query("SELECT COUNT(*) FROM `fm_ist` WHERE `time` > '".(time()-86400)."'"), 0);
echo "<div class='frends2'><img src='icon/m.gif'> <a href='ist.php'>История</a> ";
if ($istnew>0){echo "($ist)<span style='color:red'>+$istnew</span><br />";}else{echo "($ist)<br />";} echo'</div>';
$klubi= mysql_result(mysql_query("SELECT COUNT(*) FROM `fm_club`",$db), 0);
echo "<div class='frends'><img src='icon/m.gif'> <a href='clubs.php'>Клубы</a> ($klubi)<br /></div>\n";
$coaches= mysql_result(mysql_query("SELECT COUNT(*) FROM `fm_coach`",$db), 0);
echo "<div class='frends2'><img src='icon/m.gif'> <a href='coaches.php'>Тренеры</a> ($coaches)<br /></div>\n";
$gamers= mysql_result(mysql_query("SELECT COUNT(*) FROM `fm_gamers`",$db), 0);
echo "<div class='frends'><img src='icon/m.gif'> <a href='players.php'>Игроки</a> ($gamers)<br /></div>\n";
echo "<div class='frends2'><img src='icon/m.gif'> <a href='club.php'>Мой клуб</a><br /></div>";
echo "<div class='frends'><img src='icon/m.gif'> <a href='coach.php'>Мой Тренер</a><br /></div>";
echo "<div class='frends2'><img src='icon/m.gif'> <a href='gamers.php'>Мои Игроки</a><br /></div>";
echo "<div class='frends'><img src='icon/m.gif'> <a href='bank.php'>Банк</a><br /></div>";
echo "<div class='frends2'><img src='icon/m.gif'> <a href='info.php'>Информация</a><br /></div>";
echo '</div>';
include_once '../sys/inc/tfoot.php';

?>