From cc478ddc4e5b62cba3dfe8ac32f269c9faee245f Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Tue, 10 Mar 2009 20:24:40 +0000 Subject: [PATCH] Possible fix for badly rewritten links --- inc/libs/rewrite_functions.php | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/inc/libs/rewrite_functions.php b/inc/libs/rewrite_functions.php index 2b1a74b26b..36399f1662 100644 --- a/inc/libs/rewrite_functions.php +++ b/inc/libs/rewrite_functions.php @@ -54,12 +54,11 @@ function REWRITE_LINKS ($HTML) { $target = constant('URL')."/cms/"; // Convert modules.php?module=... - $test = preg_replace("/".$URL."\\/modules.php\\?module=/i", $target, $HTML); + $test = preg_replace("/".$URL."/modules.php?module=/i", $target, $HTML); if (eregi(SERVER_URL, $test)) { - // Konvert URLs from my server - $URL = str_replace("/", "\\/", constant('SERVER_URL')); - $test = preg_replace("/".$URL."\\/modules.php\\?module=/i", constant('SERVER_URL')."/cms/", $test); + // Convert URLs from my server + $test = preg_replace("/".constant('SERVER_URL')."/modules.php?module=/i", constant('SERVER_URL')."/cms/", $test); } // END - if // Strip slashes as above for the main URL -- 2.39.5