CC-2184: Hardcoded CSS path should be relative path instead
-Make '/' the default root
This commit is contained in:
parent
ba66746a00
commit
fae3f3a03f
38 changed files with 303 additions and 298 deletions
|
@ -66,8 +66,15 @@ class Application_Common_OsPath{
|
|||
|
||||
public static function getBaseDir() {
|
||||
$baseUrl = dirname($_SERVER['SCRIPT_NAME']);
|
||||
if (strcmp($baseUrl, '/') ==0) $baseUrl = "";
|
||||
|
||||
|
||||
if ($baseUrl[0] != "/") {
|
||||
$baseUrl = "/".$baseUrl;
|
||||
}
|
||||
|
||||
if ($baseUrl[strlen($baseUrl) -1] != "/") {
|
||||
$baseUrl = $baseUrl."/";
|
||||
}
|
||||
|
||||
return $baseUrl;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue