From 9c535da52888d60aecef9799062974e375f22f82 Mon Sep 17 00:00:00 2001 From: Nathan Guse Date: Tue, 17 Sep 2013 22:00:06 -0500 Subject: [ticket/11850] page_name contains controller request rather than query string Fixing tests PHPBB3-11850 --- phpBB/phpbb/session.php | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'phpBB') diff --git a/phpBB/phpbb/session.php b/phpBB/phpbb/session.php index 52f621dbf6..1752291cf2 100644 --- a/phpBB/phpbb/session.php +++ b/phpBB/phpbb/session.php @@ -87,6 +87,12 @@ class phpbb_session $page_name = (substr($script_name, -1, 1) == '/') ? '' : basename($script_name); $page_name = urlencode(htmlspecialchars($page_name)); + $symfony_request_path = $phpbb_filesystem->clean_path($symfony_request->getPathInfo()); + if ($symfony_request_path !== '/') + { + $page_name .= $symfony_request_path; + } + // current directory within the phpBB root (for example: adm) $root_dirs = explode('/', str_replace('\\', '/', phpbb_realpath($root_path))); $page_dirs = explode('/', str_replace('\\', '/', phpbb_realpath('./'))); @@ -103,12 +109,7 @@ class phpbb_session } // Current page from phpBB root (for example: adm/index.php?i=10&b=2) - $symfony_request_path = $phpbb_filesystem->clean_path($symfony_request->getPathInfo()); $page = (($page_dir) ? $page_dir . '/' : '') . $page_name; - if ($symfony_request_path !== '/') - { - $page .= $symfony_request_path; - } if ($query_string) { $page .= '?' . $query_string; -- cgit v1.2.1