From 9f9a89c78ef8998dea9d611a21889a09b6e4952f Mon Sep 17 00:00:00 2001 From: Henry Sudhof Date: Wed, 24 Sep 2008 12:29:57 +0000 Subject: [PATCH] Merging 8927, 8928, 8929, 8930 git-svn-id: file:///svn/phpbb/trunk@8931 89ea8834-ac86-4346-8a33-228a782c2dd0 --- phpBB/includes/functions_display.php | 6 +++--- phpBB/memberlist.php | 12 +++++------- phpBB/styles/prosilver/template/memberlist_body.html | 8 ++++++++ 3 files changed, 16 insertions(+), 10 deletions(-) diff --git a/phpBB/includes/functions_display.php b/phpBB/includes/functions_display.php index 7412bc1559..480d82e5f6 100644 --- a/phpBB/includes/functions_display.php +++ b/phpBB/includes/functions_display.php @@ -236,7 +236,7 @@ function display_forums($root_data = '', $display_moderators = true, $return_mod // Handle marking posts if ($mark_read == 'forums' || $mark_read == 'all') { - $redirect = build_url('mark'); + $redirect = build_url('mark', 'hash'); $token = request_var('hash', ''); if (check_link_hash($token, 'global')) { @@ -1007,7 +1007,7 @@ function watch_topic_forum($mode, &$s_watching, $user_id, $forum_id, $topic_id, $table_sql = ($mode == 'forum') ? FORUMS_WATCH_TABLE : TOPICS_WATCH_TABLE; $where_sql = ($mode == 'forum') ? 'forum_id' : 'topic_id'; $match_id = ($mode == 'forum') ? $forum_id : $topic_id; - $u_url = "uid={$user->data['user_id']}&hash=" . generate_link_hash("{$mode}_$match_id"); + $u_url = "uid={$user->data['user_id']}"; $u_url .= ($mode == 'forum') ? '&f' : '&f=' . $forum_id . '&t'; // Is user watching this thread? @@ -1116,7 +1116,7 @@ function watch_topic_forum($mode, &$s_watching, $user_id, $forum_id, $topic_id, if ($can_watch) { - $s_watching['link'] = append_sid("view$mode", "$u_url=$match_id&" . (($is_watching) ? 'unwatch' : 'watch') . "=$mode&start=$start"); + $s_watching['link'] = append_sid("view$mode", "$u_url=$match_id&" . (($is_watching) ? 'unwatch' : 'watch') . "=$mode&start=$start&hash=" . generate_link_hash("{$mode}_$match_id")); $s_watching['title'] = $user->lang[(($is_watching) ? 'STOP' : 'START') . '_WATCHING_' . strtoupper($mode)]; $s_watching['is_watching'] = $is_watching; } diff --git a/phpBB/memberlist.php b/phpBB/memberlist.php index 361c9921a5..7ae305f90f 100644 --- a/phpBB/memberlist.php +++ b/phpBB/memberlist.php @@ -1209,7 +1209,6 @@ switch ($mode) // We do not use request_var() here directly to save some calls (not all variables are set) $check_params = array( - 'start' => array('start', 0), 'g' => array('g', 0), 'sk' => array('sk', $default_key), 'sd' => array('sd', 'a'), @@ -1250,8 +1249,7 @@ switch ($mode) $sort_params[] = $param; } } - - $u_hide_find_member = append_sid('memberlist', implode('&', $params)); + $u_hide_find_member = append_sid('memberlist', "start=$start" . implode('&', $params)); $params[] = "mode=$mode"; $sort_params[] = "mode=$mode"; @@ -1465,7 +1463,7 @@ switch ($mode) 'JABBER_IMG' => $user->img('icon_contact_jabber', $user->lang['JABBER']), 'SEARCH_IMG' => $user->img('icon_user_search', $user->lang['SEARCH']), - 'U_FIND_MEMBER' => ($config['load_search'] || $auth->acl_get('a_')) ? append_sid('memberlist', 'mode=searchuser') : '', + 'U_FIND_MEMBER' => ($config['load_search'] || $auth->acl_get('a_')) ? append_sid('memberlist', 'mode=searchuser' . (($start) ? "&start=$start" : '')) : '', 'U_HIDE_FIND_MEMBER' => ($mode == 'searchuser') ? $u_hide_find_member : '', 'U_SORT_USERNAME' => $sort_url . '&sk=a&sd=' . (($sort_key == 'a' && $sort_dir == 'a') ? 'd' : 'a'), 'U_SORT_FROM' => $sort_url . '&sk=b&sd=' . (($sort_key == 'b' && $sort_dir == 'a') ? 'd' : 'a'), @@ -1619,15 +1617,15 @@ function _sort_last_active($first, $second) { global $id_cache, $sort_dir; - $lesser_than = ($sort_dir === 'a') ? -1 : 1; + $lesser_than = ($sort_dir === 'd') ? -1 : 1; if (isset($id_cache[$first]['group_leader']) && $id_cache[$first]['group_leader'] && (!isset($id_cache[$second]['group_leader']) || !$id_cache[$second]['group_leader'])) { - return 1; + return -1; } else if (isset($id_cache[$second]['group_leader']) && (!isset($id_cache[$first]['group_leader']) || !$id_cache[$first]['group_leader']) && $id_cache[$second]['group_leader']) { - return -1; + return 1; } else { diff --git a/phpBB/styles/prosilver/template/memberlist_body.html b/phpBB/styles/prosilver/template/memberlist_body.html index 85f92ebe8a..7bfa02175d 100644 --- a/phpBB/styles/prosilver/template/memberlist_body.html +++ b/phpBB/styles/prosilver/template/memberlist_body.html @@ -109,11 +109,19 @@ + + + + + + + +
{L_RANK}{L_GROUP_MEMBERS}{L_USERNAME}{L_POSTS}{L_WEBSITE}{L_COMMA_SEPARATOR}{L_LOCATION}{L_JOINED}{L_LAST_ACTIVE} {L_GROUP_MEMBERS}