mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-30 21:40:43 +02:00
- updated all code to use the request class instead of any direct access to
super globals - disabled super globals in common.php. See commit r9101 for more information - cleaned up/simplified a few lines along the way. git-svn-id: file:///svn/phpbb/trunk@9102 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
@@ -68,7 +68,7 @@ function display_forums($root_data = '', $display_moderators = true, $return_mod
|
||||
}
|
||||
else if ($config['load_anon_lastread'] || $user->data['is_registered'])
|
||||
{
|
||||
$tracking_topics = (isset($_COOKIE[$config['cookie_name'] . '_track'])) ? ((STRIP) ? stripslashes($_COOKIE[$config['cookie_name'] . '_track']) : $_COOKIE[$config['cookie_name'] . '_track']) : '';
|
||||
$tracking_topics = request::variable($config['cookie_name'] . '_track', '', false, request::COOKIE);
|
||||
$tracking_topics = ($tracking_topics) ? tracking_unserialize($tracking_topics) : array();
|
||||
|
||||
if (!$user->data['is_registered'])
|
||||
@@ -1044,7 +1044,7 @@ function watch_topic_forum($mode, &$s_watching, $user_id, $forum_id, $topic_id,
|
||||
if (!is_null($notify_status) && $notify_status !== '')
|
||||
{
|
||||
|
||||
if (isset($_GET['unwatch']))
|
||||
if (request::is_set('unwatch', request::GET))
|
||||
{
|
||||
$uid = request_var('uid', 0);
|
||||
if ($uid != $user_id)
|
||||
@@ -1053,7 +1053,7 @@ function watch_topic_forum($mode, &$s_watching, $user_id, $forum_id, $topic_id,
|
||||
$message = $user->lang['ERR_UNWATCHING'] . '<br /><br />' . sprintf($user->lang['RETURN_' . strtoupper($mode)], '<a href="' . $redirect_url . '">', '</a>');
|
||||
trigger_error($message);
|
||||
}
|
||||
if ($_GET['unwatch'] == $mode)
|
||||
if (request::variable('unwatch', '', false, request::GET) == $mode)
|
||||
{
|
||||
$is_watching = 0;
|
||||
|
||||
@@ -1086,12 +1086,12 @@ function watch_topic_forum($mode, &$s_watching, $user_id, $forum_id, $topic_id,
|
||||
}
|
||||
else
|
||||
{
|
||||
if (isset($_GET['watch']))
|
||||
if (request::is_set('watch', request::GET))
|
||||
{
|
||||
$token = request_var('hash', '');
|
||||
$redirect_url = append_sid("view$mode", "$u_url=$match_id&start=$start");
|
||||
|
||||
if ($_GET['watch'] == $mode && check_link_hash($token, "{$mode}_$match_id"))
|
||||
if (request::variable('watch', '', false, request::GET) == $mode && check_link_hash($token, "{$mode}_$match_id"))
|
||||
{
|
||||
$is_watching = true;
|
||||
|
||||
@@ -1117,7 +1117,7 @@ function watch_topic_forum($mode, &$s_watching, $user_id, $forum_id, $topic_id,
|
||||
}
|
||||
else
|
||||
{
|
||||
if (isset($_GET['unwatch']) && $_GET['unwatch'] == $mode)
|
||||
if (request::variable('unwatch', '', false, request::GET) == $mode)
|
||||
{
|
||||
login_box();
|
||||
}
|
||||
|
Reference in New Issue
Block a user