CSS Changes not updating after upgrade

Community Forums Forums General Discussion CSS Changes not updating after upgrade

This topic is: not resolved

This topic contains 8 replies, has 3 voices, and was last updated by  avhslibrary 1 year, 4 months ago.

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #55856

    jaehouse
    Participant
    Post count: 3

    I created a custom Genesis child theme and up to now have never had trouble with updates. Am I missing something that I should be doing in order for changes to my child theme css to show up?

    When I inspect element it shows me the old styles under my child theme style.css but with a ?ver2.0. after it.

    What am I doing wrong?

    http://theindiechicks.com
    #55865

    RobG
    Participant
    Post count: 1055

    What seems to not be showing up?


    To speed up the process please post the link to the website in question.

    We recommend using Firebug to view source codes http://getfirebug.com/

    RobGoss WordPress Developer
    We build WordPress websites for your business or personal goals
    http://www.robgoss.com / Follow me Twitter / https://twitter.com/robgoss

    #55867

    jaehouse
    Participant
    Post count: 3

    Any changes I make to my stylesheet in my child theme folder

    #55874

    RobG
    Participant
    Post count: 1055

    What theme are you using?


    To speed up the process please post the link to the website in question.

    We recommend using Firebug to view source codes http://getfirebug.com/

    RobGoss WordPress Developer
    We build WordPress websites for your business or personal goals
    http://www.robgoss.com / Follow me Twitter / https://twitter.com/robgoss

    #55875

    jaehouse
    Participant
    Post count: 3

    I created my own Genesis Child Theme… That’s why I’m asking, is there something I should be doing? I don’t understand why when I inspect element, it’s showing me styles in style.css?ver=2.0 IN my child theme folder. And any changes I make to my style sheet remain saved but don’t show up in the site. And when I inspect element again, it shows me the old styles.

    #55910

    RobG
    Participant
    Post count: 1055

    I’m not really sure if it’s someting you created you might want to back step to see if your coding is incorrect.


    To speed up the process please post the link to the website in question.

    We recommend using Firebug to view source codes http://getfirebug.com/

    RobGoss WordPress Developer
    We build WordPress websites for your business or personal goals
    http://www.robgoss.com / Follow me Twitter / https://twitter.com/robgoss

    #55942

    jaehouse
    Participant
    Post count: 3

    Got it. It’s called CSS caching (which I had never heard of)… Added the code below to functions.php and it referenced my stylesheet again:

    function remove_cssjs_ver( $src ) {
        if( strpos( $src, '?ver=' ) )
            $src = remove_query_arg( 'ver', $src );
        return $src;
    }
    add_filter( 'style_loader_src', 'remove_cssjs_ver', 10, 2 );
    add_filter( 'script_loader_src', 'remove_cssjs_ver', 10, 2 );

    Thanks for your help.

    #55982

    RobG
    Participant
    Post count: 1055

    Glad you got it sorted out.


    To speed up the process please post the link to the website in question.

    We recommend using Firebug to view source codes http://getfirebug.com/

    RobGoss WordPress Developer
    We build WordPress websites for your business or personal goals
    http://www.robgoss.com / Follow me Twitter / https://twitter.com/robgoss

    #57216

    avhslibrary
    Participant
    Post count: 18

    Hi, Jaehouse–

    I’m having a similar problem. I’m using w3 total cache. Are you using something similar?

    I see the code you came up with and you mentioned it’s for your style sheet. Are you using a stylesheet which is named style.css?

    My website is amadorvalleyhs.org. I make changes to the stylesheet but they only appear if I deactivate W3 Total Cache.

    Thanks,

    Erik

Viewing 9 posts - 1 through 9 (of 9 total)

You must be logged in to reply to this topic.