From ecc6777cf905f2fc25f1466e7fcf9b6e5cf5a5f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ali=20Y=C4=B1lmaz?= Date: Fri, 7 Apr 2023 13:46:44 +0300 Subject: [PATCH] 5.5.8 --- Mind.php | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/Mind.php b/Mind.php index c432f44..b761646 100755 --- a/Mind.php +++ b/Mind.php @@ -3,7 +3,7 @@ /** * * @package Mind - * @version Release: 5.5.7 + * @version Release: 5.5.8 * @license GPL3 * @author Ali YILMAZ * @category Php Framework, Design pattern builder for PHP. @@ -4517,7 +4517,13 @@ public function route($uri, $file, $cache=null){ } if($this->base_url != '/'){ - $request = str_replace($this->base_url, '', rawurldecode($_SERVER['REQUEST_URI'])); + if(strstr(rawurldecode($_SERVER['REQUEST_URI']), $this->base_url)){ + $request = rawurldecode($_SERVER['REQUEST_URI']); + for ($i=0; $i < mb_strlen($this->base_url); $i++) { + $request[$i] = ' '; + } + $request = str_replace(' ', '', $request); + } } else { $request = trim(rawurldecode($_SERVER['REQUEST_URI']), '/'); }