From 6fe3f0e7d4ae91a9b742b373791de812404217fa Mon Sep 17 00:00:00 2001 From: Meik Sievertsen Date: Fri, 8 Oct 2004 10:59:23 +0000 Subject: [PATCH] - load_moderators taken into account at index.php - added S_UNREAD_TOPIC to viewforum - changed S_UNREAD to S_UNREAD_POST in viewtopic git-svn-id: file:///svn/phpbb/trunk@4995 89ea8834-ac86-4346-8a33-228a782c2dd0 --- phpBB/index.php | 2 +- phpBB/viewforum.php | 4 ++-- phpBB/viewtopic.php | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/phpBB/index.php b/phpBB/index.php index 32c60f0785..b307b44c4c 100644 --- a/phpBB/index.php +++ b/phpBB/index.php @@ -22,7 +22,7 @@ $auth->acl($user->data); $user->setup(); include($phpbb_root_path . 'includes/functions_display.' . $phpEx); -display_forums(); +display_forums('', $config['load_moderators']); // Set some stats, get posts count from forums data if we... hum... retrieve all forums data $total_posts = $config['num_posts']; diff --git a/phpBB/viewforum.php b/phpBB/viewforum.php index 1b03061a2e..ddc41db941 100644 --- a/phpBB/viewforum.php +++ b/phpBB/viewforum.php @@ -155,7 +155,7 @@ if ($forum_data['left_id'] != $forum_data['right_id'] - 1) } else { - $template->assign_var('S_HAS_SUBFORUM', FALSE); + $template->assign_var('S_HAS_SUBFORUM', false); } get_moderators($moderators, $forum_id); @@ -501,7 +501,6 @@ if ($forum_data['forum_type'] == FORUM_POST || ($forum_data['forum_flags'] & 16) } // Goto message generation - // Note: Template this a little bit more to allow style authors seperating goto_page, next, prev and pagination block? if (($replies + 1) > $config['posts_per_page']) { $total_pages = ceil(($replies + 1) / $config['posts_per_page']); @@ -565,6 +564,7 @@ if ($forum_data['forum_type'] == FORUM_POST || ($forum_data['forum_flags'] & 16) 'S_TOPIC_TYPE_SWITCH' => ($s_type_switch == $s_type_switch_test) ? -1 : $s_type_switch_test, 'S_TOPIC_TYPE' => $row['topic_type'], 'S_USER_POSTED' => (!empty($row['mark_type'])) ? true : false, + 'S_UNREAD_TOPIC' => $unread_topic, 'S_TOPIC_REPORTED' => (!empty($row['topic_reported']) && $auth->acl_gets('m_', $forum_id)) ? TRUE : FALSE, 'S_TOPIC_UNAPPROVED' => (!$row['topic_approved'] && $auth->acl_gets('m_approve', $forum_id)) ? TRUE : FALSE, diff --git a/phpBB/viewtopic.php b/phpBB/viewtopic.php index 1f927b99e8..bf2fcb83dd 100644 --- a/phpBB/viewtopic.php +++ b/phpBB/viewtopic.php @@ -1272,7 +1272,7 @@ for ($i = 0, $end = sizeof($post_list); $i < $end; ++$i) 'S_POST_REPORTED' => ($row['post_reported'] && $auth->acl_get('m_', $forum_id)) ? TRUE : FALSE, 'S_DISPLAY_NOTICE' => $display_notice && $row['post_attachment'], 'S_FRIEND' => ($row['friend']) ? true : false, - 'S_UNREAD' => ($user->data['user_id'] != ANONYMOUS && $row['post_time'] > $user->data['user_lastvisit'] && $row['post_time'] > $topic_last_read) ? true : false, + 'S_UNREAD_POST' => ($user->data['user_id'] != ANONYMOUS && $row['post_time'] > $user->data['user_lastvisit'] && $row['post_time'] > $topic_last_read) ? true : false, 'S_FIRST_UNREAD' => ($unread_post_id == $row['post_id']) ? true : false, 'S_CUSTOM_FIELDS' => (sizeof($cp_row)) ? true : false );