1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-05-06 23:55:26 +02:00

Do not include hash in redirect back

git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@8930 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
Henry Sudhof 2008-09-24 12:23:57 +00:00
parent f761a26e8d
commit 1e7a75db8f

View File

@ -237,7 +237,7 @@ function display_forums($root_data = '', $display_moderators = true, $return_mod
// Handle marking posts // Handle marking posts
if ($mark_read == 'forums' || $mark_read == 'all') if ($mark_read == 'forums' || $mark_read == 'all')
{ {
$redirect = build_url('mark'); $redirect = build_url('mark', 'hash');
$token = request_var('hash', ''); $token = request_var('hash', '');
if (check_link_hash($token, 'global')) if (check_link_hash($token, 'global'))
{ {
@ -1010,7 +1010,7 @@ function watch_topic_forum($mode, &$s_watching, $user_id, $forum_id, $topic_id,
$table_sql = ($mode == 'forum') ? FORUMS_WATCH_TABLE : TOPICS_WATCH_TABLE; $table_sql = ($mode == 'forum') ? FORUMS_WATCH_TABLE : TOPICS_WATCH_TABLE;
$where_sql = ($mode == 'forum') ? 'forum_id' : 'topic_id'; $where_sql = ($mode == 'forum') ? 'forum_id' : 'topic_id';
$match_id = ($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'; $u_url .= ($mode == 'forum') ? '&f' : '&f=' . $forum_id . '&t';
// Is user watching this thread? // Is user watching this thread?
@ -1119,7 +1119,7 @@ function watch_topic_forum($mode, &$s_watching, $user_id, $forum_id, $topic_id,
if ($can_watch) if ($can_watch)
{ {
$s_watching['link'] = append_sid("{$phpbb_root_path}view$mode.$phpEx", "$u_url=$match_id&" . (($is_watching) ? 'unwatch' : 'watch') . "=$mode&start=$start"); $s_watching['link'] = append_sid("{$phpbb_root_path}view$mode.$phpEx", "$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['title'] = $user->lang[(($is_watching) ? 'STOP' : 'START') . '_WATCHING_' . strtoupper($mode)];
$s_watching['is_watching'] = $is_watching; $s_watching['is_watching'] = $is_watching;
} }