mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-11 22:08:54 +00:00
Merging 8927, 8928, 8929, 8930
git-svn-id: file:///svn/phpbb/trunk@8931 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
884cde18fe
commit
9f9a89c78e
3 changed files with 16 additions and 10 deletions
|
@ -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;
|
||||
}
|
||||
|
|
|
@ -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
|
||||
{
|
||||
|
|
|
@ -109,11 +109,19 @@
|
|||
<table class="table1" cellspacing="1">
|
||||
<thead>
|
||||
<tr>
|
||||
<!-- IF not S_LEADERS_SET -->
|
||||
<th class="name"><span class="rank-img"><a href="{U_SORT_RANK}">{L_RANK}</a></span><a href="{U_SORT_USERNAME}"><!-- IF S_SHOW_GROUP -->{L_GROUP_MEMBERS}<!-- ELSE -->{L_USERNAME}<!-- ENDIF --></a></th>
|
||||
<th class="posts"><a href="{U_SORT_POSTS}#memberlist">{L_POSTS}</a></th>
|
||||
<th class="info"><a href="{U_SORT_WEBSITE}#memberlist">{L_WEBSITE}</a>{L_COMMA_SEPARATOR}<a href="{U_SORT_LOCATION}">{L_LOCATION}</a></th>
|
||||
<th class="joined"><a href="{U_SORT_JOINED}#memberlist">{L_JOINED}</a></th>
|
||||
<!-- IF U_SORT_ACTIVE --><th class="active"><a href="{U_SORT_ACTIVE}#memberlist">{L_LAST_ACTIVE}</a></th><!-- ENDIF -->
|
||||
<!-- ELSE -->
|
||||
<th class="name">{L_GROUP_MEMBERS}</th>
|
||||
<th class="posts"> </th>
|
||||
<th class="info"> </th>
|
||||
<th class="joined"> </th>
|
||||
<!-- IF U_SORT_ACTIVE --><th class="active"> </th><!-- ENDIF -->
|
||||
<!-- ENDIF -->
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
|
Loading…
Add table
Reference in a new issue