ThinkChat2.0新版上线,更智能更精彩,支持会话、画图、阅读、搜索等,送10W Token,即刻开启你的AI之旅 广告
HTTP请求头信息的名称不区分大小写,并且\_会自动转换为- print\_r( Request::header() ); print\_r( Request::header('www.hezhidz.com') ); 五、请求信息 序号 方法 说明 1 host 当前访问域名或者IP 2 scheme 当前访问协议 3 port 当前访问的端口 4 remotePort 当前请求的REMOTE\_PORT 5 protocol 当前请求的SERVER\_PROTOCOL 6 contentType 当前请求的CONTENT\_TYPE 7 domain 当前包含协议的域名 8 subDomain 当前访问的子域名 9 panDomain 当前访问的泛域名 10 rootDomain 当前访问的根域名 11 url 当前完整URL 12 baseUrl 当前URL(不含QUERY\_STRING) 13 query 当前请求的QUERY\_STRING参数 14 baseFile 当前执行的文件 15 root URL访问根地址 16 rootUrl URL访问根目录 17 pathinfo 当前请求URL的pathinfo信息(含URL后缀) 18 ext 当前URL的访问后缀 19 time 获取当前请求的时间 20 type 当前请求的资源类型 21 method 当前请求类型 22 rule 当前请求的路由对象实例 23 controller 当前请求的控制器名 24 action 当前请求的操作名 print\_r( Request::host() ); print\_r( Request::url() ); print\_r( Request::controller() ); print\_r( Request::action() );