©
This document usesPHP Chinese website manualRelease
PragmaHTTP / 1.0 一般报头是特定于实现的报头可以具有沿着请求-响应链的各种效果。它用于向后兼容 HTTP / 1.1 缓存,而Cache-ControlHTTP / 1.1 缓存不存在。
注意:Pragma未指定用于 HTTP 响应,因此不为普通 HTTP / 1.1 的可靠替换Cache-Control首部,虽然它不表现一样Cache-Control: no-cache,如果Cache-Control在请求中省略报头字段。使用Pragma仅适用于 HTTP / 1.0 客户端的向后兼容性。
|
Header type |
General header, but response behavior is not specified and thus implementation-specific. |
|---|---|
|
Forbidden header name |
no |
|
CORS-safelisted response-header |
yes |
Pragma: no-cache
无缓存
和Cache-Control: no-cache一样。在释放缓存副本之前,强制高速缓存将请求提交给原始服务器进行验证。
Pragma: no-cache
|
Specification |
Title |
|---|---|
|
RFC 7234, section 5.4: Pragma |
Hypertext Transfer Protocol (HTTP/1.1): Caching |
|
Feature |
Chrome |
Firefox |
Edge |
Internet Explorer |
Opera |
Safari |
|---|---|---|---|---|---|---|
|
Basic Support |
(Yes) |
(Yes) |
(Yes) |
(Yes) |
(Yes) |
(Yes) |
|
Feature |
Android |
Chrome for Android |
Edge mobile |
Firefox for Android |
IE mobile |
Opera Android |
iOS Safari |
|---|---|---|---|---|---|---|---|
|
Basic Support |
(Yes) |
(Yes) |
(Yes) |
(Yes) |
(Yes) |
(Yes) |
(Yes) |
Cache-Control
Expires