Файл: mob-lave.ru/moduls/info/statistic.php
Строк: 118
<?php
require_once '../../core/set.php';
// --------- Топ 10 чат ------- //
if(isset($_GET['chat'])){
$set['title'] = 'Топ 10 чаттеров';
require_once H.'core/head.php';
require_once H.'core/panel.php';
echo '<div class="navig">'.$home. $z.'<a href="/moduls/info/statistic.php">Статистика</a>'.$z. $set['title'].'</div>';
$k_post = mysql_result(mysql_query("SELECT COUNT(*) FROM `$system[perfix]_user_ank` WHERE `count_post_chat` > '0'"),0);
if ($k_post == 0) echo '<div class="menu">Лидеров нет</div>';
$q = mysql_query("SELECT `count_post_chat`,`id_user` FROM `$system[perfix]_user_ank` WHERE `count_post_chat` > '0' ORDER BY `count_post_chat` DESC LIMIT 10");
while($post = mysql_fetch_assoc($q)){
$avtor = mysql_fetch_assoc(mysql_query("SELECT `id`,`login` FROM `$system[perfix]_users` WHERE `id` = '$post[id_user]'"));
echo '<div class="menu_touch"><a href="/?login='.$avtor['login'].'">';
echo online($avtor['id']). $avtor['login'].'<br />
Сообщений: <b>'.num($post['count_post_chat']).'</b></a></div>';
}
echo '<div class="navig">'.$home. $z.'<a href="/moduls/info/statistic.php">Статистика</a>'.$z. $set['title'].'</div>';
require_once H.'core/foot.php';
exit();
}
// --------- Топ 10 тем ------- //
if(isset($_GET['them'])){
$set['title'] = 'Топ 10 форумчан (темы)';
require_once H.'core/head.php';
require_once H.'core/panel.php';
echo '<div class="navig">'.$home. $z.'<a href="/moduls/info/statistic.php">Статистика</a>'.$z. $set['title'].'</div>';
$k_post = mysql_result(mysql_query("SELECT COUNT(*) FROM `$system[perfix]_user_ank` WHERE `count_them` > '0'"),0);
if ($k_post == 0) echo '<div class="menu">Лидеров нет</div>';
$q = mysql_query("SELECT `count_them`,`id_user` FROM `$system[perfix]_user_ank` WHERE `count_them` > '0' ORDER BY `count_them` DESC LIMIT 10");
while($post = mysql_fetch_assoc($q)){
$avtor = mysql_fetch_assoc(mysql_query("SELECT `id`,`login` FROM `$system[perfix]_users` WHERE `id` = '$post[id_user]'"));
echo '<div class="menu_touch"><a href="/?login='.$avtor['login'].'">';
echo online($avtor['id']). $avtor['login'].'<br />
Создано тем: <b>'.num($post['count_them']).'</b></a></div>';
}
echo '<div class="navig">'.$home. $z.'<a href="/moduls/info/statistic.php">Статистика</a>'.$z. $set['title'].'</div>';
require_once H.'core/foot.php';
exit();
}
// --------- Топ 10 комм форума ------- //
if(isset($_GET['post_them'])){
$set['title'] = 'Топ 10 форумчан (сообщ)';
require_once H.'core/head.php';
require_once H.'core/panel.php';
echo '<div class="navig">'.$home. $z.'<a href="/moduls/info/statistic.php">Статистика</a>'.$z. $set['title'].'</div>';
$k_post = mysql_result(mysql_query("SELECT COUNT(*) FROM `$system[perfix]_user_ank` WHERE `count_post_them` > '0'"),0);
if ($k_post == 0) echo '<div class="menu">Лидеров нет</div>';
$q = mysql_query("SELECT `count_post_them`,`id_user` FROM `$system[perfix]_user_ank` WHERE `count_post_them` > '0' ORDER BY `count_post_them` DESC LIMIT 10");
while($post = mysql_fetch_assoc($q)){
$avtor = mysql_fetch_assoc(mysql_query("SELECT `id`,`login` FROM `$system[perfix]_users` WHERE `id` = '$post[id_user]'"));
echo '<div class="menu_touch"><a href="/?login='.$avtor['login'].'">';
echo online($avtor['id']). $avtor['login'].'<br />
Сообщений: <b>'.num($post['count_post_them']).'</b></a></div>';
}
echo '<div class="navig">'.$home. $z.'<a href="/moduls/info/statistic.php">Статистика</a>'.$z. $set['title'].'</div>';
require_once H.'core/foot.php';
exit();
}
// --------- Топ 10 богатые ------- //
if(isset($_GET['money'])){
$set['title'] = 'Самые богатые';
require_once H.'core/head.php';
require_once H.'core/panel.php';
echo '<div class="navig">'.$home. $z.'<a href="/moduls/info/statistic.php">Статистика</a>'.$z. $set['title'].'</div>';
$k_post = mysql_result(mysql_query("SELECT COUNT(*) FROM `$system[perfix]_users` WHERE `money` > '0'"),0);
if ($k_post == 0) echo '<div class="menu">Лидеров нет</div>';
$q = mysql_query("SELECT `money`,`id`,`login` FROM `$system[perfix]_users` WHERE `money` > '0' ORDER BY `money` DESC LIMIT 10");
while($post = mysql_fetch_assoc($q)){
echo '<div class="menu_touch"><a href="/?login='.$post['login'].'">';
echo online($post['id']). $post['login'].'<br />
Монет: <b>'.num($post['money']).'</b></a></div>';
}
echo '<div class="navig">'.$home. $z.'<a href="/moduls/info/statistic.php">Статистика</a>'.$z. $set['title'].'</div>';
require_once H.'core/foot.php';
exit();
}
$set['title'] = 'Статистика сайта';
require_once H.'core/head.php';
require_once H.'core/panel.php';
echo '<div class="navig">'.$home. $z. $set['title'].'</div>';
echo '<div class="razdel">Топ 10 активных обитателей</div>';
echo '<div class="menu_touch"><a href="/moduls/info/statistic.php?chat"><div id="dark" class="icon-bubbles"></div> Сообщения в чате</a></div>';
echo '<div class="menu_touch"><a href="/moduls/info/statistic.php?them"><div id="dark" class="icon-file4"></div> Тем в форуме</a></div>';
echo '<div class="menu_touch"><a href="/moduls/info/statistic.php?post_them"><div id="dark" class="icon-bubble"></div> Сообщения в форуме</a></div>';
echo '<div class="menu_touch"><a href="/moduls/info/statistic.php?money"><div id="dark" class="icon-coin"></div> Самые богатые</a></div>';
echo '<div class="razdel">Авторитетность сайта (Тиц, PR)</div>';
echo '<div class="mess"><a href="http://www.cy-pr.com/" target="_blank"><img src="http://www.cy-pr.com/e/micro-book.ru_1_107.138.206.gif" border="0" width="88" height="31" alt="Проверка тИЦ и PR"/></a></div>';
echo '<div class="navig">'.$home. $z. $set['title'].'</div>';
require_once H.'core/foot.php';
?>