获取Http请求中Host值:
$_SERVER["HTTP_HOST"](返回值为域名或IP)
获取服务器IP:
GetHostByName($_SERVER['SERVER_NAME'])
接受请求的服务器IP:
$_SERVER["SERVER_ADDR"](有时候获取不到,推荐用:GetHostByName($_SERVER['SERVER_NAME']))
获取客户端IP:
$_SERVER['REMOTE_ADDR']
获取服务器解译引擎:
$_SERVER['SERVER_SOFTWARE']
获取服务器CPU数量:
$_SERVER['PROCESSOR_IDENTIFIER']
获取服务器系统目录:
$_SERVER['SystemRoot']
获取服务器域名:
$_SERVER['SERVER_NAME'](建议使用:$_SERVER["HTTP_HOST"])
获取用户域名:
$_SERVER['USERDOMAIN']
获取服务器语言:
$_SERVER['HTTP_ACCEPT_LANGUAGE']
获取服务器Web端口:
$_SERVER['SERVER_PORT']
© Allow specification reprint