简体   繁体   English

PHP会话添加标题实用程序:无缓存

[英]PHP Session Adding Headers Pragma: no-cache

Hi People, i have problem with http headers request, when i test header i get this response 嗨,大家好,我在测试HTTP标头时遇到了问题,当我测试标头时,我得到了这个响应

HTTP/1.1 200 OK
Date: Sat, 29 Oct 2016 14:24:31 GMT
Server: Apache
X-Powered-By: PHP/5.6.27
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-
    check=0
Pragma: no-cache
Set-Cookie: PHPSESSID=2d17992cfbd621c51eca940df478b89a; path=/
Vary: Accept-Encoding,User-Agent
X-Frame-Options: SAMEORIGIN
X-XSS-Protection: 1; mode=block
X-Content-Security-Policy: allow 'self';
X-Content-Type-Options: nosniff
Cache-Control: max-age=604800, must-revalidate
Connection: close
Transfer-Encoding: chunked
Content-Type: text/html; charset=UTF-8
Content-Language: it-it

This part ist come out only if i have session_start() on page 仅当我在页面上具有session_start()时,此部分才会出现

Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-
    check=0
Pragma: no-cache

On clean pages .php or .html pages i get this respond 在干净的页面.php或.html页面上,我得到此响应

  HTTP/1.1 200 OK
    Date: Sat, 29 Oct 2016 14:34:27 GMT
    Server: Apache
    Last-Modified: Sat, 29 Oct 2016 13:15:00 GMT
    Accept-Ranges: bytes
    Content-Length: 314
    Vary: Accept-Encoding,User-Agent
    Cache-Control: max-age=604800, must-revalidate
    Expires: Sat, 29 Oct 2016 14:34:27 GMT
    X-Frame-Options: SAMEORIGIN
    X-XSS-Protection: 1; mode=block
    X-Content-Security-Policy: allow 'self';
    X-Content-Type-Options: nosniff
    Connection: close
    Content-Type: text/html; charset=UTF-8
    Content-Language: it-it

I try search evrywhere but no idea im bloked Sombody have idea why session_start(); 我尝试搜索evrywhere,但没有一个想法让Sombody知道为什么session_start();。 add

Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-
    check=0
Pragma: no-cache

in http headers???????? 在http标题中????????

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 什么可以将“Pragma:no-cache”添加到我的响应标头中? (阿帕奇,PHP) - What could be adding “Pragma:no-cache” to my response Headers? (Apache, PHP) nginx + php-fpm忽略无缓存头 - nginx + php-fpm ignores no-cache headers 如何在Debain上使用Concrete5对“编译指示:无缓存”进行故障排除? - How to troubleshoot “Pragma: no-cache” with Concrete5 on Debain? Laravel响应Cache-Control标头始终包含'no-cache' - Laravel response Cache-Control headers always containing 'no-cache' 目标特定文件-NO-CACHE PHP - Target Specific File - NO-CACHE PHP 是否不添加缓存meta + php标头会导致css / js也不缓存? - Will adding no cache meta + php headers cause css/js not to cache too? PHP-session_cache_limiter()和标头之间的区别? - PHP - Difference between session_cache_limiter() and headers? PHP 错误无法发送会话缓存限制器 - 标头已发送 - PHP Error Cannot send session cache limiter - headers already sent Symfony ajax 响应但带有标头:HTTP/1.0 200 OK 缓存控制:无缓存日期 - Symfony ajax Response but with headers: HTTP/1.0 200 OK Cache-Control: no-cache Date Firefox实时HTTP标头,在Cache-Control之后使用大括号:no-cache - Firefox live http headers, curley braces after Cache-Control: no-cache
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM