From: Roland Häder Date: Wed, 18 Nov 2009 11:31:54 +0000 (+0000) Subject: Fix for double-add of URL X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=bdd8949ee8b336ef33a7c83ae2c00ac0134dad0f;p=mailer.git Fix for double-add of URL --- diff --git a/inc/functions.php b/inc/functions.php index ef7e638836..5557b88024 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -3855,8 +3855,11 @@ function encodeUrl ($url, $outputMode = '0') { } // END - if } // END - if - // Add {?URL?} - $url = '{?URL?}/' . $url; + // Add {?URL?} ? + if ((substr($url, 0, strlen(getConfig('URL'))) != getConfig('URL')) && (substr($url, 0, 7) == '{?URL?}')) { + // Add it + $url = '{?URL?}/' . $url; + } // END - if // Return the URL return $url;