mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-21 13:54:02 -07:00
parent
6378c43ef7
commit
dd638fda7e
3 changed files with 12 additions and 6 deletions
|
@ -17,6 +17,7 @@ $page_cfg['load_tpl_vars'] = array(
|
|||
|
||||
$show_last_topic = true;
|
||||
$last_topic_max_len = 28;
|
||||
$show_online_users = true;
|
||||
$show_subforums = true;
|
||||
|
||||
$datastore->enqueue(array(
|
||||
|
@ -402,6 +403,9 @@ if (IS_AM) {
|
|||
}
|
||||
}
|
||||
|
||||
// Display page
|
||||
define('SHOW_ONLINE', $show_online_users);
|
||||
|
||||
if (isset($_GET['map'])) {
|
||||
$template->assign_vars(array('PAGE_TITLE' => $lang['FORUM_MAP']));
|
||||
}
|
||||
|
|
|
@ -520,7 +520,6 @@ $bb_cfg['allow_change'] = [
|
|||
];
|
||||
|
||||
$bb_cfg['show_jumpbox'] = true;
|
||||
$bb_cfg['show_online_userlist_index'] = true;
|
||||
|
||||
$bb_cfg['trash_forum_id'] = 0; // (int) 7
|
||||
|
||||
|
|
|
@ -28,7 +28,7 @@ if ($logged_in) {
|
|||
}
|
||||
|
||||
// Online userlist
|
||||
if ($bb_cfg['show_online_userlist_index']) {
|
||||
if (defined('SHOW_ONLINE') && SHOW_ONLINE) {
|
||||
$online_full = !empty($_REQUEST['online_full']);
|
||||
$online_list = $online_full ? 'online_' . $userdata['user_lang'] : 'online_short_' . $userdata['user_lang'];
|
||||
|
||||
|
@ -38,13 +38,16 @@ if ($bb_cfg['show_online_userlist_index']) {
|
|||
'cnt' => '',
|
||||
);
|
||||
|
||||
if (!${$online_list} = CACHE('bb_cache')->get($online_list)) {
|
||||
require INC_DIR . '/online_userlist.php';
|
||||
if (defined('IS_GUEST') && !(IS_GUEST || IS_USER)) {
|
||||
$template->assign_var('SHOW_ONLINE_LIST');
|
||||
|
||||
${$online_list} = CACHE('bb_cache')->get($online_list);
|
||||
if (!${$online_list} = CACHE('bb_cache')->get($online_list)) {
|
||||
require INC_DIR . '/online_userlist.php';
|
||||
|
||||
${$online_list} = CACHE('bb_cache')->get($online_list);
|
||||
}
|
||||
}
|
||||
|
||||
$template->assign_var('SHOW_ONLINE_LIST');
|
||||
$template->assign_vars(array(
|
||||
'TOTAL_USERS_ONLINE' => ${$online_list}['stat'],
|
||||
'LOGGED_IN_USER_LIST' => ${$online_list}['userlist'],
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue