Fixed some URL comparison issues
authorAlexander Ebert <ebert@woltlab.com>
Fri, 31 Oct 2014 12:52:52 +0000 (13:52 +0100)
committerAlexander Ebert <ebert@woltlab.com>
Fri, 31 Oct 2014 12:52:52 +0000 (13:52 +0100)
wcfsetup/install/files/lib/page/AbstractPage.class.php

index 6134c5d0f30dda5060676b050b11867f02487d1b..0447ea221649089bf451e097d98e241ac49bc75c 100644 (file)
@@ -9,7 +9,6 @@ use wcf\system\request\RequestHandler;
 use wcf\system\WCF;
 use wcf\util\HeaderUtil;
 use wcf\util\StringUtil;
-use wcf\util\UserUtil;
 
 /**
  * Abstract implementation of a page which fires the default event actions of a
@@ -190,6 +189,10 @@ abstract class AbstractPage implements IPage, ITrackablePage {
                        if (!StringUtil::isUTF8($requestURI)) {
                                $requestURI = StringUtil::convertEncoding('ISO-8859-1', 'UTF-8', $requestURI);
                        }
+                       if (strpos($requestURI, '%') !== false) {
+                               $requestURI = urldecode($requestURI);
+                       }
+                       
                        $requestURL = parse_url($requestURI);
                        
                        $redirect = false;
@@ -208,7 +211,7 @@ abstract class AbstractPage implements IPage, ITrackablePage {
                                }
                        }
                        
-                       if ($redirect) {
+                       if (false && $redirect) {
                                $redirectURL = $this->canonicalURL;
                                if (!empty($requestURL['query'])) {
                                        $queryString = $requestURL['query'];