Improve usage in command line
This commit is contained in:
parent
160490215d
commit
cf2f3ba3f6
1 changed files with 10 additions and 10 deletions
|
|
@ -369,16 +369,16 @@ define("ARROWUP","⇧");
|
||||||
// Url of NOALYSS (http://...)
|
// Url of NOALYSS (http://...)
|
||||||
//
|
//
|
||||||
if (!defined("NOALYSS_URL")) {
|
if (!defined("NOALYSS_URL")) {
|
||||||
if ( isset ( $_SERVER)) {
|
if ( isset ( $_SERVER['SERVER_NAME'])) {
|
||||||
$protocol = "http";
|
$protocol = "http";
|
||||||
if (isset ($_SERVER['REQUEST_SCHEME'])) {
|
if (isset ($_SERVER['REQUEST_SCHEME'])) {
|
||||||
$protocol = $_SERVER['REQUEST_SCHEME'];
|
$protocol = $_SERVER['REQUEST_SCHEME'];
|
||||||
}
|
}
|
||||||
$base = $protocol . '://' .
|
$base = $protocol . '://' .
|
||||||
$_SERVER['SERVER_NAME'] .
|
$_SERVER['SERVER_NAME'] .
|
||||||
":" . $_SERVER['SERVER_PORT'] .
|
":" . $_SERVER['SERVER_PORT'] .
|
||||||
dirname($_SERVER['PHP_SELF']);
|
dirname($_SERVER['PHP_SELF']);
|
||||||
define("NOALYSS_URL", $base);
|
define("NOALYSS_URL", $base);
|
||||||
}else {
|
}else {
|
||||||
define("NOALYSS_URL","command-line");
|
define("NOALYSS_URL","command-line");
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue