detect localhost by HTTP_HOST instead of SERVER_ADDR
This commit is contained in:
parent
cf18f8b90c
commit
ca03de048e
1 changed files with 1 additions and 1 deletions
|
@ -135,7 +135,7 @@
|
|||
*/
|
||||
private function isLocalhost()
|
||||
{
|
||||
return ($_SERVER['SERVER_ADDR'] == '127.0.0.1' || $_SERVER['SERVER_ADDR'] = '::1');
|
||||
return (strpos($_SERVER['HTTP_HOST'], '.') === false);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue