mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-09 16:05:00 +02:00
[ticket/12510] Convert & to & in build_url() when no params are stripped.
PHPBB3-12510
This commit is contained in:
parent
3c86a9bcca
commit
eddb420375
@ -2356,6 +2356,10 @@ function build_url($strip_vars = false)
|
|||||||
{
|
{
|
||||||
$redirect = $phpbb_path_helper->strip_url_params($redirect, $strip_vars, false);
|
$redirect = $phpbb_path_helper->strip_url_params($redirect, $strip_vars, false);
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$redirect = str_replace('&', '&', $redirect);
|
||||||
|
}
|
||||||
|
|
||||||
return $redirect . ((strpos($redirect, '?') === false) ? '?' : '');
|
return $redirect . ((strpos($redirect, '?') === false) ? '?' : '');
|
||||||
}
|
}
|
||||||
|
@ -44,6 +44,11 @@ class phpbb_build_url_test extends phpbb_test_case
|
|||||||
't',
|
't',
|
||||||
'phpBB/index.php?',
|
'phpBB/index.php?',
|
||||||
),
|
),
|
||||||
|
array(
|
||||||
|
'viewtopic.php?t=5&f=4',
|
||||||
|
false,
|
||||||
|
'phpBB/viewtopic.php?t=5&f=4',
|
||||||
|
),
|
||||||
array(
|
array(
|
||||||
'viewtopic.php?f=2&style=1&t=6',
|
'viewtopic.php?f=2&style=1&t=6',
|
||||||
'f',
|
'f',
|
||||||
|
Loading…
x
Reference in New Issue
Block a user