Clean CSS cache


#1

I just installed EE on a new server and deployed my website there. All works great! But then I notice a 2px div miss aligned. Easy fix… nope!

EasyEngine caches all CSS with version at the end. Even ee clean --all didn’t help. I had to add a code in my WordPress theme to remove the ?v=4.3 at the end. How can I clean / fix this?


#2

It runs deeper than that; we strip query strings from our assets and still have trouble with style.css caching all the time


#3

Did you try cleaning your browser cache?


#4

yes

If I try to access the CSS file directly with versioning and without there’s two different files.

Cleaned cache, no other cache in place, also tried with anonymous tab.


#5

Which caching are you using with that particular site?


#6

started with --wpredis, then updated it to only --wp and still no results. when I did ee clean --all the output was that every cache was cleaned, however, didn’t reflected anything on the website.


#7

If you are using --wp switch, EE will not cache anything.

  1. Are you using any caching plugin?
  2. Are you using any reverse proxy i.e cloudflare/incapsula or CDN services?

#8

Hello again. I started with --wpredis, switched to --wp, didn’t work, switched back to --wpredis again.

  1. I’m not using any caching plugin. It’s a clean install with a theme that we developed from underscores.me no extra plugins at all installed!
  2. no cloudflare is turned off for the domain.

#9

Sorry I can’t help you then. I have been using EE since 2.x and I haven’t encounter similar problem.

Usually when I’m developing any WP site with EE,

  1. I would use --wp switch.
  2. Stop any caching services, e.g sudo service memcached stop, redis-server etc.
  3. Edit PHP-Fpm opcache settings, or disable them.
  4. Use browser profile with caching disabled.
  5. Bypass cloudflare caching or use development mode for quick fix. Not forgetting to purge all caching even when it’s not necessary.
  6. Disable WP external connection with “define(‘WP_HTTP_BLOCK_EXTERNAL’, true);” in wp-config.php.

Hope the EE guys can shed some light on your problem.


#10

Log in on the server (ssh) and try the following command:

sudo ee clean --all

If you’re using any kind of CDN, don’t forget to purge them aswell.


#11