?
本文檔使用 php中文網(wǎng)手冊(cè) 發(fā)布
Pragma
HTTP / 1.0 一般報(bào)頭是特定于實(shí)現(xiàn)的報(bào)頭可以具有沿著請(qǐng)求-響應(yīng)鏈的各種效果。它用于向后兼容 HTTP / 1.1 緩存,而Cache-Control
HTTP / 1.1 緩存不存在。
注意:Pragma
未指定用于 HTTP 響應(yīng),因此不為普通 HTTP / 1.1 的可靠替換Cache-Control
首部,雖然它不表現(xiàn)一樣Cache-Control: no-cache
,如果Cache-Control
在請(qǐng)求中省略報(bào)頭字段。使用Pragma
僅適用于 HTTP / 1.0 客戶(hù)端的向后兼容性。
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
無(wú)緩存
和Cache-Control: no-cache
一樣。在釋放緩存副本之前,強(qiáng)制高速緩存將請(qǐng)求提交給原始服務(wù)器進(jìn)行驗(yàn)證。
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