2014-09-24 89 views
0

我已經設置了下一行nginx的:雙緩存控制線

add_header Cache-Control "max-age=259200, public"; 

但是從我的響應報頭的樣子:

Cache-Control:max-age=259200, public 
Cache-Control:no-store, no-cache, must-revalidate, post-check=0, pre-check=0 
Connection:keep-alive 
Content-Encoding:gzip 
Content-Type:text/html 
Date:Wed, 24 Sep 2014 10:21:32 GMT 
Expires:Thu, 19 Nov 1981 08:52:00 GMT 
Pragma:no-cache 
Server:nginx/1.1.19 
Transfer-Encoding:chunked 
X-Powered-By:PHP/5.3.10-1ubuntu3 

我已經檢查過我不從服務器端腳本(PHP)發送其他頭文件。 我該如何解決這個問題......?

更新: 我發現,這僅僅是在PHP-生成的響應...

回答

0

我解決了這個問題session_start();前加入下一行session_cache_limiter(false);

+0

查看header-more模塊,可以合併標題。 – Melvyn 2014-09-25 06:38:44