From b13ff9b8324ad38a493c65cb261b8256d5d8f421 Mon Sep 17 00:00:00 2001 From: Benjamin Renard Date: Thu, 20 Aug 2020 18:11:48 +0200 Subject: [PATCH] LSurl::redirect: fix handling absolute URL without protocol For instance "//localhost/phpldapadmin/") --- src/includes/class/class.LSurl.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/includes/class/class.LSurl.php b/src/includes/class/class.LSurl.php index 37692f4d..a848bc04 100644 --- a/src/includes/class/class.LSurl.php +++ b/src/includes/class/class.LSurl.php @@ -194,7 +194,7 @@ class LSurl extends LSlog_staticLoggerClass { if ($go===false) $go = ""; - if (preg_match('#^https?://#',$go)) { + if (preg_match('#^(https?:)?//#',$go)) { $url = $go; } else {