mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-01 13:48:37 +02:00
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:
parent
47f40ed6bd
commit
4cf4dd50a5
@ -431,7 +431,7 @@ class Director {
|
|||||||
$url = ereg_replace('([^:])//','\\1/',$url);
|
$url = ereg_replace('([^:])//','\\1/',$url);
|
||||||
|
|
||||||
// Only bother comparing the URL to the absolute version if $url looks like a 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();
|
$base1 = self::absoluteBaseURL();
|
||||||
if(substr($url,0,strlen($base1)) == $base1) return substr($url,strlen($base1));
|
if(substr($url,0,strlen($base1)) == $base1) return substr($url,strlen($base1));
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user