请问oneinstac里的apache如何设置页面缓存时间

问答中心分类: OneinStack请问oneinstac里的apache如何设置页面缓存时间
zhengcf 提问 10月 前

在httpd.conf里面设置了header set cache-control “max-age=3600″好像不起做用,请大神指导下
<IfModule mod_headers.c>
AddOutputFilterByType DEFLATE text/html text/plain text/css text/xml text/javascript
<FilesMatch “\.(js|css|html|htm|png|jpg|swf|pdf|shtml|xml|flv|gif|ico|jpeg)$”>
header set cache-control “max-age=3600″
RequestHeader edit “If-None-Match” “^(.*)-gzip(.*)$” “$1$2”
Header edit “ETag” “^(.*)-gzip(.*)$” “$1$2”
</FilesMatch>
DeflateCompressionLevel 6
SetOutputFilter DEFLATE
</IfModule>