Please check carefully this change
This commit is contained in:
parent
0dd98b21f3
commit
ec8d5b4fe4
|
@ -4348,7 +4348,9 @@ function ui_get_full_url($url='', $no_proxy=false, $add_name_php_file=false, $me
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if ($proxy) {
|
if ($proxy) {
|
||||||
$fullurl .= '/';
|
if (is_metaconsole() && $metaconsole_root) {
|
||||||
|
$fullurl .= 'enterprise/meta/';
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
if ($add_name_php_file) {
|
if ($add_name_php_file) {
|
||||||
$fullurl .= $_SERVER['SCRIPT_NAME'];
|
$fullurl .= $_SERVER['SCRIPT_NAME'];
|
||||||
|
@ -4362,10 +4364,14 @@ function ui_get_full_url($url='', $no_proxy=false, $add_name_php_file=false, $me
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (substr($fullurl, -1, 1) === substr($url, 0, 1)) {
|
// Add last slash if missing.
|
||||||
if (substr($fullurl, -1, 1) === '/') {
|
if (substr($fullurl, -1, 1) !== '/') {
|
||||||
$url = substr($url, 1);
|
$fullurl .= '/';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Remove starting slash if present.
|
||||||
|
if (substr($url, 0, 1) === '/') {
|
||||||
|
$url = substr($url, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
return $fullurl.$url;
|
return $fullurl.$url;
|
||||||
|
|
Loading…
Reference in New Issue