Title: Minify Cache-Control possible bug?
Last modified: March 8, 2018

---

# Minify Cache-Control possible bug?

 *  [glasswalkernyc](https://wordpress.org/support/users/glasswalkernyc/)
 * (@glasswalkernyc)
 * [8 years, 3 months ago](https://wordpress.org/support/topic/minify-cache-control-possible-bug/)
 * Something strange is happening with the Cache-Control headers for the generated
   minify files, forcing them to have “max-age=0, public, max-age=31536000”, and
   therefore they are not being cached by my CDN.
 * check it out:
 * curl -I [http://www.<mydomain&gt](http://www.<mydomain&gt);.com/wp-content/cache/
   minify/18035.css?x11355
 * HTTP/1.1 200 OK
    Date: Thu, 08 Mar 2018 03:15:44 GMT Server: Apache/2.4.7 (Ubuntu)
   Content-Length: 1900874 X-Powered-By: W3 Total Cache/0.9.6 Pragma: public Vary:
   Accept-Encoding Last-Modified: Wed, 07 Mar 2018 18:54:52 GMT ETag: “pub1520448892”**
   Cache-Control: max-age=0, public, max-age=31536000** Access-Control-Allow-Origin:*
   Expires: Fri, 08 Mar 2019 03:08:59 GMT X-Content-Type-Options: nosniff Content-
   Type: text/css; charset=utf-8
 * What’s weird is that the .htaccess file looks to be correct:
 * :/var/www/<mydomain>/wp-content/cache/minify$ cat .htaccess
    # BEGIN W3TC Minify
   cache FileETag MTime Size <IfModule mod_mime.c> AddType text/css .css_gzip AddEncoding
   gzip .css_gzip AddType application/x-javascript .js_gzip AddEncoding gzip .js_gzip
   </IfModule> <IfModule mod_deflate.c> <IfModule mod_setenvif.c> SetEnvIfNoCase
   Request_URI \.css_gzip$ no-gzip SetEnvIfNoCase Request_URI \.js_gzip$ no-gzip
   </IfModule> </IfModule> <IfModule mod_headers.c> Header set X-Powered-By “W3 
   Total Cache/0.9.6” Header set Vary “Accept-Encoding” Header set Pragma “public”**
   Header set Cache-Control “max-age=31536000, public”** </IfModule> # END W3TC 
   Minify cache # BEGIN W3TC Minify core <IfModule mod_rewrite.c> RewriteEngine 
   On RewriteBase /wp-content/cache/minify/ RewriteCond %{HTTP:Accept-Encoding} 
   gzip RewriteRule .* – [E=APPEND_EXT:_gzip] RewriteCond %{REQUEST_FILENAME}%{ENV:
   APPEND_EXT} -f RewriteRule (.*) $1%{ENV:APPEND_EXT} [L] RewriteRule ^(.+\.(css
   |js))$ /index.php [L] </IfModule> # END W3TC Minify core
 * Can anyone verify this? I should note that I’m also running mod_pagespeed, but
   turning that on and off doesn’t seem to change anything.

Viewing 2 replies - 1 through 2 (of 2 total)

 *  [sdawales](https://wordpress.org/support/users/sdawales/)
 * (@sdawales)
 * [8 years, 3 months ago](https://wordpress.org/support/topic/minify-cache-control-possible-bug/#post-10051301)
 * Could the first be for logged in users and the second for everyone else?
 *  Thread Starter [glasswalkernyc](https://wordpress.org/support/users/glasswalkernyc/)
 * (@glasswalkernyc)
 * [8 years, 3 months ago](https://wordpress.org/support/topic/minify-cache-control-possible-bug/#post-10051389)
 * I don’t think that’s it. It seems like headers are being added after the .htaccess
   file that are over-writing the correct ones, I just don’t know where.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Minify Cache-Control possible bug?’ is closed to new replies.

 * ![](https://ps.w.org/w3-total-cache/assets/icon-256x256.png?rev=1041806)
 * [W3 Total Cache](https://wordpress.org/plugins/w3-total-cache/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/w3-total-cache/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/w3-total-cache/)
 * [Active Topics](https://wordpress.org/support/plugin/w3-total-cache/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/w3-total-cache/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/w3-total-cache/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [glasswalkernyc](https://wordpress.org/support/users/glasswalkernyc/)
 * Last activity: [8 years, 3 months ago](https://wordpress.org/support/topic/minify-cache-control-possible-bug/#post-10051389)
 * Status: not resolved