0

I’m absolutely fed up at this stage. I just activated a new theme on my WordPress site. I activated it at about 7pm GMT and since then I’ve been trying to change the style. I’ve updated the CSS (I’m using SCSS and compiling it into style.css with CodeKit) but the changes don’t take effect.

I get the feeling it’s something to do with WordPress because I’ve tried in several browsers and it’s the same — the CSS will not update! It won’t even update locally. For example, I removed a style which was changing a h1’s font-size to 45px at a 992px breakpoint. But it still shows up and beside the style.css there is a version number:

enter image description here

I’m using Starkers as the starting point for my theme but I don’t think it has anything to do with that. I also tried clearing my browser cache but the fact that the site has the same issue on all browsers leads to believe it’s a WordPress issue.

0

WordPress doesn't actively participate in the process of actually serving your stylesheet file. It links to it in page source, but as actual physical file the handling of it isn't done by WordPress core and passed to the webserver to be served as any static file would be.

?ver=3.9.1 is added by default, if actual version isn't provided when queueing the style. This is used for cache busting and has no impact on serving file, as far as CSS is concerned this part is meaningless.

Looking at your stylesheet in REDbot there doesn't seem to be any caching issues either.

From this information I would say you are either looking at wrong file or file wasn't successfully updated on server.

  • Thanks Rarst, just before checking back here I checked CodeKit again and it turns out that it had automatically changed the output directory for the compiled CSS. It wasn’t overwriting the style.css in the theme’s root but it had created a style.css in a css/ directory I had set up for other CSS files. Sigh… I need to switch to Grunt or Gulp for compiling. Thanks for your reply though, the info you posted is good to know anyway :-) – user51214 Jul 5 '14 at 21:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy