Solved

wordpress not updating style.css in browser

Posted on 2015-02-23
13
86 Views
Last Modified: 2015-03-03
I am trying to work updating css on a site in wordpress.
I am finding that even though I update the style.css its not updating on my site.
If I look in my resources it says it's loading style.css?ver=1.0
How can I get it to update in my browser?
I looked and I don't have any cache type plugins.
0
Comment
Question by:rivkamak
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 4
  • 3
13 Comments
 
LVL 17

Expert Comment

by:OriNetworks
ID: 40627360
You dont need any plugins for cache, the browser caches files by default. Clear the cache of your browser and you should get the new style.css if you mention what browser you are using i can also provide directions.  It might also help to use developer tools that come with your browser to see if the style.css that is loading. For example F12 developer tools while using internet explorer has a network tab that you can use to see if the style.css is loading a cached file (http code 304) or fresh from the server (http 200)
0
 
LVL 38

Expert Comment

by:Tom Beck
ID: 40627912
This is a common problem with Wordpress. There are numerous solutions like this one to combat the problem.

http://www.quickonlinetips.com/archives/2011/12/force-browser-css-refresh/
0
 

Author Comment

by:rivkamak
ID: 40628424
I'm using chrome and firefox.
even when I force a full refresh or open incognito,  i'm still seeing the old style sheet
0
Instantly Create Instructional Tutorials

Contextual Guidance at the moment of need helps your employees adopt to new software or processes instantly. Boost knowledge retention and employee engagement step-by-step with one easy solution.

 

Author Comment

by:rivkamak
ID: 40628454
I cleared my cache. I tried the idea from that file you included to tell it to put a different version number up there, but it's still showing ver=1.0 even though I put a different version number in my functions file

You can view my site here:
http://devorah.designalivesandbox.com/site2/
The words in large that say "our courses", is supposed to be in yellow, not black.
0
 
LVL 38

Expert Comment

by:Tom Beck
ID: 40628666
This style.css: http://devorah.designalivesandbox.com/site2/wp-content/themes/cw-business-lite/style.css

When I put that url in a browser that has never visited that site (no cache, no version number), it should give me the file straight from the server with the font color set to yellow. But it doesn't. The color is defined as #192836. The developer tools show code 200 for the style.css file on the site.

There has to be something more basic than a cache causing this.
0
 
LVL 17

Expert Comment

by:OriNetworks
ID: 40628734
Since i am most familiar with IE developer tools i can give you an example of how i would check if the element is using the style from styl.css.

Im developer tools use the first tab (dom explorer) to select an element that contains font that you think should be yellow. On the right side it will display the style inheritance. Check to make sure styl.css is listed and using the font-color property and value you expect. If it is crossed out, find the style above that is overwriting the property. If it is not listed, you may have to adjust you css selector in style.css
0
 

Author Comment

by:rivkamak
ID: 40628801
I am refering to the child theme that isn't updating
http://devorah.designalivesandbox.com/site2/wp-content/themes/cw-business-lite-child/style.css
this file shows up with custom css classes. But if you load the site itself, they don't show up.
0
 
LVL 17

Expert Comment

by:OriNetworks
ID: 40628810
I understand unfortunately im not in front of a computer with tools right now otherwise i would check for you. The same steps i have explained can be used to see if the child theme is being overwritten or even being evaluated at all
0
 
LVL 38

Expert Comment

by:Tom Beck
ID: 40628954
I can tell you that the style is not being overridden. Read my comment 28623033

This is the only definition listed and it's from style.css.

#features-two h3 {
    color: #192836;
    font-size: 39px;
    font-weight: 700;
    text-align: center;
    text-transform: uppercase;
    width: 100%;
}
0
 

Author Comment

by:rivkamak
ID: 40629286
My point is not if my specific class is being overwritten or not. my point is that it is not loading the correct stylesheet into my browser.

when you load the stylesheet itself it shows version 1.1 in the comment.
if you load my website, the file css that is loading is 1.0

why is wordpress pulling an older version and not updating the cache?
0
 
LVL 38

Expert Comment

by:Tom Beck
ID: 40629340
Here's the problem.

This file has the color change. Note the folder cw-business-lite-child:
http://devorah.designalivesandbox.com/site2/wp-content/themes/cw-business-lite-child/style.css

This file is what is being called from the page. Folder cv-business-child:
http://devorah.designalivesandbox.com/site2/wp-content/themes/cv-business-child/style.css?ver=1.0
 
The latter style.css file has this import statement. Note the folder cw-business-lite:
@import url(../cw-business-lite/style.css);

http://devorah.designalivesandbox.com/site2/wp-content/themes/cw-business-lite/style.css

Does not have the color change.
0
 

Accepted Solution

by:
rivkamak earned 0 total points
ID: 40630904
I solved the problem.
I needed to install a plugin called 'clear cache'
Thank you for your help anyway
0
 

Author Closing Comment

by:rivkamak
ID: 40641437
No one else got the correct answer. I solved it myself.
0

Featured Post

Don't Cry: How Liquid Web is Ensuring Security

WannaCry is just the start. Read how Liquid Web is protecting itself and its customers against new threats.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Like there are many different versions of Wordpress, there are also a handful of related side projects WordPress users should be familiar with.   All of these projects are open source and GPL licensed, which means there are few restrictions to us…
WordPress is constantly evolving, and with each evolution appears to get better and better.  One of the big drawbacks prior to version 3 was that there was no way to be able to set up a custom menu from the backend. The Old Way Adding menus is…
This video teaches users how to migrate an existing Wordpress website to a new domain.
The purpose of this video is to demonstrate how to set up basic WordPress SEO. This will be demonstrated using a Windows 8 PC. The plugin used will be WordPress SEO by Yoast. Go to your WordPress login page. This will look like the following: myw…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question