Fixed dumb error in my makeRelative change

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@63537 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Sam Minnee 2008-10-02 21:05:33 +00:00
parent 47f40ed6bd
commit 4cf4dd50a5

View File

@ -431,7 +431,7 @@ class Director {
$url = ereg_replace('([^:])//','\\1/',$url);
// Only bother comparing the URL to the absolute version if $url looks like a URL.
if(preg_match('/^http[^:]+:\/\//',$url)) {
if(preg_match('/^http[^:]*:\/\//',$url)) {
$base1 = self::absoluteBaseURL();
if(substr($url,0,strlen($base1)) == $base1) return substr($url,strlen($base1));
}