server

获取server信息

函数原型:

   /**
    * 获取Server相关的数据
    * @param $index
    * @param bool $xss_clean
    * @return array|bool|string
    */
   public function server($index, $xss_clean = true)

注意字段全是小写:

[request_method] => GET
[request_uri] => /
[path_info] => /
[request_time] => 1484215271
[request_time_float] => 1484215271.2045
[server_port] => 8081
[remote_port] => 56738
[remote_addr] => 127.0.0.1
[server_protocol] => HTTP/1.1
[server_software] => swoole-http-server

results matching ""

    No results matching ""