Файл: soc-set/moduls/online/index.php
Строк: 15
<?php
require_once('../../core/start.php');
check_auth();
head('Сейчас на сайте');
panel();
$all = DB::$dbs->querySingle("SELECT COUNT(`user_id`) FROM ".USERS." WHERE `last_time` > ? ORDER BY `last_time` DESC", array((time() - 2000)));
if (empty($all)) {
    echo DIV_LI . 'На сайте никого нет' . CLOSE_DIV;
} else {
    $n = new Navigator($all,10,''); 
    $sql = DB::$dbs->query("SELECT * FROM ".USERS." WHERE `last_time` > ? ORDER BY `last_time` DESC LIMIT {$n->start()}, 10", array((time() - 2000)));
    while($ank = $sql -> fetch()) {
        echo DIV_LI . user_choice($ank['user_id'], 'link') . ' [Послед. активность: '.vrem($ank['last_time']).']' . CLOSE_DIV;            
    }    
    echo $n->navi();     
}
$array = array();
nav($array); 
require_once('../../core/stop.php');
?>