fixed errors in errors login
This commit is contained in:
parent
da2adc25d2
commit
00f5c2027c
|
@ -114,23 +114,12 @@ require_once ($ownDir . 'functions.php');
|
||||||
// If not we will get ugly warnings. Set Europe/Madrid by default
|
// If not we will get ugly warnings. Set Europe/Madrid by default
|
||||||
// Later will be replaced by the good one.
|
// Later will be replaced by the good one.
|
||||||
if (!defined('METACONSOLE')) {
|
if (!defined('METACONSOLE')) {
|
||||||
if(!isset($config["homeurl"])){
|
|
||||||
$url = explode('/', $_SERVER['REQUEST_URI']);
|
$url = explode('/', $_SERVER['REQUEST_URI']);
|
||||||
$config["homeurl"] = $url[1];
|
array_pop($url);
|
||||||
$config["homeurl_static"] = $url[1];
|
$config["homeurl"] = rtrim(join("/", $url),"/");
|
||||||
$config["error"] = "homeurl_bad_defined";
|
$config["homeurl_static"] = $config["homeurl"];
|
||||||
return;
|
|
||||||
}
|
|
||||||
else{
|
|
||||||
$url = explode('/', $_SERVER['REQUEST_URI']);
|
|
||||||
if($config["homeurl"] != '/'.$url[1]){
|
|
||||||
$config["homeurl"] = '/'.$url[1];
|
|
||||||
$config["homeurl_static"] = '/'.$url[1];
|
|
||||||
$config["error"] = "homeurl_bad_defined";
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!isset($config["homeurl_static"])) {
|
if (!isset($config["homeurl_static"])) {
|
||||||
$config["homeurl_static"] = $config["homeurl"];
|
$config["homeurl_static"] = $config["homeurl"];
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue