GET/mycode/2.gifHTTP/1.1

【表示发送的是GET请求,请求资源是/mycode/2.gif,协议HTTP/1.1】

Host:localhost

【主机】

Connection:keep-alive

【(长链接)普通报头域允许发送指定连接的选项。例如指定连接是连续,或者指定"close"选项,通知服务器,在响应完成后,关闭连接】

Cache-Control:max-age=0

【缓存指令】

Accept:image/webp,image/*,*/*;q=0.8

【表示客户端可以接受的数据类型】


Location:http://www.baidu.org/index.jsp


Server:apachetomcat


Content-Encoding:gzip

【内容编码支持gzip压缩算法】

Content-Length:80

【返回数据大小】

Content-Language:zh-cn

语言

Content-Type:text/html;charset=GB2312

【文本类型】


Eg:

HTTP/1.1 200 OK 【200 ok 表示客户端请求成功】

Date: Thu, 14 Apr 2016 07:34:28 GMT 【告诉浏览器 请求的页面的时间】

Server: Apache/2.4.18 (Win64) OpenSSL/1.0.2g PHP/5.6.19 【告诉浏览器 服务器的情况】

Last-Modified: Sun, 06 Mar 2016 04:28:44 GMT

ETag: "cf1f0-52d59c89cf7a4"

Accept-Ranges: bytes

Keep-Alive: timeout=5, max=99

Connection: Keep-Alive

Content-Type: image/gif 【文档类型】

Content-Length: 848368 【回送的数据有多少字节】


你要保守你心,胜过保守一切。

作者:刘俊涛的博客​​