Вход Регистрация
Файл: public_html/pages/who.php
Строк: 47
<?php
#-----------------------------------------------------#
#          ********* ROTORCMS *********               #
#              Made by  :  VANTUZ                     #
#               E-mail  :  visavi.net@mail.ru         #
#                 Site  :  http://pizdec.ru           #
#             WAP-Site  :  http://visavi.net          #
#                  ICQ  :  36-44-66                   #
#  Вы не имеете право вносить изменения в код скрипта #
#        для его дальнейшего распространения          #
#-----------------------------------------------------#    
require_once ('../includes/start.php');
require_once (
'../includes/functions.php');
require_once (
'../includes/header.php');
include_once (
'../themes/' . $config['themes'] . '/index.php');

if (isset(
$_GET['start'])) {
    
$start = abs(intval($_GET['start']));
} else {
    
$start = 0;
} 

show_title('site.png', 'Кто-где');
$config['newtitle'] = 'Кто-где';

$total = DB :: $dbh -> querySingle("SELECT count(*) FROM `visit`;");

if (
$total > 0) {
    if (
$total > $config['lastusers']) {
        
$total = $config['lastusers'];
    } 
    if (
$start >= $total) {
        
$start = 0;
    } 

    
$queryvisit = DB :: $dbh -> query("SELECT * FROM `visit` ORDER BY `visit_nowtime` DESC LIMIT " . $start . ", " . $config['showuser'] . ";");

    while (
$data = $queryvisit -> fetch()) {
        
$cu = round(SITETIME - $data['visit_nowtime']);

        if (
$cu < 600) {
            
$tm = '<span style="color:#00ff00">Oнлайн</span>';
        } 
        if (
$cu >= 600) {
            
$tm = round($cu / 60) . ' мин. назад';
        } 
        if (
$cu >= 3600) {
            
$tm = round($cu / 3600) . ' час. назад';
        } 
        if (
$cu >= 86400) {
            
$tm = round($cu / 86400) . ' дн. назад';
        } 

        echo 
'<div class="b"><img src="../images/img/user.gif" alt="image" /> <b><a href="../pages/anketa.php?uz=' . $data['visit_user'] . '&amp;' . SID . '">' . nickname($data['visit_user']) . '</a></b> (' . $tm . ')</div>';

        echo 
'Находится: ' . user_position($data['visit_self']) . '<br />';
        echo 
'Переходов: ' . $data['visit_count'] . '<br />';
    } 

    
page_jumpnavigation('who.php?', $config['showuser'], $start, $total);
    
page_strnavigation('who.php?', $config['showuser'], $start, $total);
} else {
    
show_error('Пользователей еще нет!');
} 

echo 
'<img src="../images/img/homepage.gif" alt="image" /> <a href="../index.php?' . SID . '">На главную</a>';
include_once 
"../themes/" . $config['themes'] . "/foot.php";

?>
Онлайн: 2
Реклама