diff --git a/dev/DebugView.php b/dev/DebugView.php index 5adbdf11f..ad7cd5524 100644 --- a/dev/DebugView.php +++ b/dev/DebugView.php @@ -51,7 +51,7 @@ class DebugView { */ public function Breadcrumbs() { $basePath = str_replace(Director::protocolAndHost(), '', Director::absoluteBaseURL()); - $relPath = parse_url(str_replace($basePath, '', $_SERVER['REQUEST_URI']), PHP_URL_PATH); + $relPath = parse_url(substr($_SERVER['REQUEST_URI'], strlen($basePath), strlen($_SERVER['REQUEST_URI'])), PHP_URL_PATH); $parts = explode('/', $relPath); $base = Director::absoluteBaseURL(); $pathPart = "";