I have a file for my homepage in the directory libraries/css/2017-06_Su****.css I'm making changes to the url path of where the background image is being pulled from and the path change is not taking changes. It's still the old path.

I tried cleaning cache, turned off caching and ran drush cc all

This is my css:


I'm changing this to:


It keeps showing up as this below no matter what I do


I'm wondering why when I modify my css in drupal 7 why the changes aren't being saved although all caching is turned off.

  • Have you try adding !important tag at the end of url.? and see if that takes effect? background:url('no******.org/images/homepage/2017/06/Summer2017_header_1170x470__.jpg') !important; it should work normally if you clear all caches from drush but seems like it's not the problem that you are having.. editing the correct file ?
    – danuddara
    Jul 10, 2017 at 21:01
  • Have you also ruled out your browser cache by force reloading the page (Ctrl + F5). Jul 10, 2017 at 21:34

3 Answers 3


I had this problem too, nothing seemed to help. It turned out that the problem was that the page for which the css did not follow the changes was created by a custom plugin. That plugin has a method that returns an array that is used for rendering.

If not specified, caching is default on, and the cached css was always used. In my case specifying the cashing had immediate effect.

In function build (which returns the render data), I changed

    return array(
        '#markup' => "<div class='taxoblock'>REST HTML</div>",);


    return array(
        '#markup' => "<div class='taxoblock'>REST HTML</div>",
        '#cache'    => array (   'max-age'   => 0 ));

Have you tried going to "Home › Administration › Configuration › Development > Performance" and disabling "Aggregate and compress CSS files"? After doing it, refresh cache.



Use the Advanced CSS/JS Aggregation module and put it into development mode.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.