mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-24 03:57:22 +08:00
when https 443 port no need
This commit is contained in:
@@ -400,7 +400,7 @@ function getSchemeAndHttpHost()
|
|||||||
$protocol = $isHttps ? 'https' : 'http';
|
$protocol = $isHttps ? 'https' : 'http';
|
||||||
$port = $_SERVER['SERVER_PORT'];
|
$port = $_SERVER['SERVER_PORT'];
|
||||||
$result = "$protocol://" . $_SERVER['HTTP_HOST'];
|
$result = "$protocol://" . $_SERVER['HTTP_HOST'];
|
||||||
if ($port != 80) {
|
if ((!$isHttps && $port != 80) || ($isHttps && $port != 443)) {
|
||||||
$result .= ":$port";
|
$result .= ":$port";
|
||||||
}
|
}
|
||||||
return $result;
|
return $result;
|
||||||
|
|||||||
Reference in New Issue
Block a user