php中304是什么意思,php – 我要发送什么标题与304响应?

这个

blog post为了驯服“有条件的”野兽而帮助我了很多.

一个有趣的摘录(与本答案有部分矛盾)指出:

If a normal response would have included an ETag header, that header must also be included in the 304 response.

Cache headers (Expires, Cache-Control, and/or Vary), if their values might differ from those sent in a previous response.

以下200个请求…

HTTP/1.1 200 OK

Server: nginx/0.8.52

Date: Thu, 18 Nov 2010 16:04:38 GMT

Content-Type: image/png

Last-Modified: Thu, 15 Oct 2009 02:04:11 GMT

Expires: Thu, 31 Dec 2010 02:04:11 GMT

Cache-Control: max-age=315360000

Accept-Ranges: bytes

Content-Length: 6394

Via: 1.1 proxyIR.my.corporate.proxy.name:8080 (IronPort-WSA/6.3.3-015)

Connection: keep-alive

Proxy-Connection: keep-alive

X-Junk: xxxxxxxxxxxxxxxx

…其最佳有效304对应.

HTTP/1.1 304 Not Modified

Server: nginx/0.8.52

Date: Thu, 18 Nov 2010 16:10:35 GMT

Expires: Thu, 31 Dec 2011 16:10:35 GMT

Cache-Control: max-age=315360000

Via: 1.1 proxyIR.my.corporate.proxy.name:8080 (IronPort-WSA/6.3.3-015)

Connection: keep-alive

Proxy-Connection: keep-alive

X-Junk: xxxxxxxxxxx

请注意,Expires标题最多为RFC-2616 14.21的当前日期.

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值