DNotes LLC

DNotes LLC

Drupal development, hosting, and consulting

Why is all my CSS gone? ...drush cc

So, there are probably many reasons you might be getting a page like this one, with no CSS whatsoever. I've discovered a few. My most recent surprise was drush cc.

At least in my case, it looks like clearing that "css and js" cache is a bad idea on a site with page caching turned on, because anonymous users will see the WSOC (white screen of confusion - just a little shy of the WSOD).

But, it should be noted that in some cases you want to see what Drupal spits out before you hack it into submission with CSS, and there's no need to be clearing database tables for that; just use the stark theme.

Reasons why your CSS disappears:

  • Some weird browser issue - try ctrl-f5
  • Clearing the "CSS and JS" cache using drush cc on a site with page caching - clear the whole cache instead
  • Enabling the stark theme - you may want to do this to check out what Drupal looks like before you theme it