Файл: user/inc/users.php
Строк: 63
<?php
$set['title'] = 'Пользователи';
#Считаем число юзеров
$us_counter = count::query('user');
$us_guest = count::query('guests', "`date_last` > '" . (time() - $set['user_online']) . "'");
if ($us_guest > 0) {
$us_guest = "$us_guest";
} else {
$us_guest = null;
}
$us_new = count::query('user', " `date_reg` > '" . (time() - $set['user_reg_time']) . "'");
if ($us_new > 0) {
$us_new = "$us_new";
} else {
$us_new = null;
}
$us_online = count::query('user', " `date_last` > '" . (time() - $set['user_online']) . "'");
if ($us_online > 0) {
$us_online = "$us_online";
} else {
$us_online = null;
}
include_once H . 'sys/user/other/users_inc.php';
echo "<div class='$div_mod'>";
echo "<a href='people_search'><span class='fa fa-search fa-fw'></span> " . lang('Поиск людей') . "</a>";
echo "</div>";
echo "<div class='$div_mod'>";
echo "<a href='users_list'><span class='fa fa-users fa-fw'></span> " . lang('Пользователи') . " <span class='label label-default pull-right'>$us_counter</span></a>";
echo "</div>";
echo "<div class='$div_mod'>";
echo "<a href='online'><span class='fa fa-laptop fa-fw'></span> " . lang('Онлайн пользователи') . " <span class='label label-default pull-right'>$us_online</span></a>";
echo "</div>";
echo "<div class='$div_mod'>";
echo "<a href='users_new'><span class='fa fa-user-plus fa-fw'></span> " . lang('Новые') . " <span class='label label-default pull-right'>$us_new</span></a>";
echo "</div>";
echo "<div class='$div_mod'>";
echo "<a href='online_guest'><span class='fa fa-user-secret fa-fw'></span> " . lang('Гости сайта') . " <span class='label label-default pull-right'>$us_guest</span></a>";
echo "</div>";