Wordpress for Linux - Max-age从未设置

时间:2017-10-24 11:02:51

标签: linux wordpress azure

我已经在azure上为linux app部署了一个wordpress。它工作正常,但我无法获得Cache-Control标头来设置max-age。 我正在使用w3总缓存插件,并设置了“设置过期标题”选项,值为31536000,“设置缓存控制策略”为缓存,其中包含css,js和media的max-age。

然后我可以看到htaccess文件中所做的所有正确更改。 但是,max-age值永远不会在响应Cache-Control标头中设置

我运行了一个phpinfo(),结果如下

Apache Version  Apache/2.4.25 (Unix) OpenSSL/1.0.2g PHP/7.1.2
Apache API Version  20120211
Server Administrator    [no address given]
Hostname:Port   172.18.0.5:80
User/Group  www-data(33)/33
Max Requests    Per Child: 0 - Keep Alive: on - Max Per Connection: 100
Timeouts    Connection: 60 - Keep-Alive: 5
Virtual Server  Yes
Server Root /usr/local/httpd
Loaded Modules  core mod_so http_core prefork mod_authn_file mod_authn_core mod_authz_host mod_authz_groupfile mod_authz_user mod_authz_core mod_access_compat mod_auth_basic mod_reqtimeout mod_filter mod_mime mod_log_config mod_env mod_headers mod_setenvif mod_version mod_ssl mod_unixd mod_status mod_autoindex mod_dir mod_alias mod_rewrite mod_php7

在加载的模块中没有列出mod_expires,这可能表明这可能是问题所在。

但我该如何安装呢?

0 个答案:

没有答案
相关问题