• Hi

    Most of my client site has coding in the Storefront child theme that I did years ago.

    I’ve updated all plugins and wordpress version recently.

    I notice that when I try to make changes in that area to the CSS in the Child Theme, the changes are NOT reflected on the live site. I clear cache but still cannot see the changes.

    Maybe I need to add all the coding now in the Additional CSS in the Appearance/Additional CSS area ?

    Is that the best area to ADD code to it reflects more important to read the CODE ?

    If someone could please advise as I have 2 clients sites currently when I change some CSS code in the Child Theme, it isn’t reflected at all.

    Thanks

    Kristin

Viewing 5 replies - 1 through 5 (of 5 total)
  • Hey there, @kristinubute! Thanks for contacting us. I’m happy to help you.

    CSS added to the child theme should work, it is not needed to add it on the Additional CSS area.

    To confirm, the CSS that is not showing on the site used to work before you updated the plugins and WordPress or what is not working are new modifications?

    Have you checked the browser console to see if there’s something overwriting the CSS code you added?

    Can you please try adding it to the Additional CSS area to check if it works?

    Please let us know how it goes.

    Looking forward to your reply.

    Have a wonderful day!

    Thread Starter kristinubute

    (@kristinubute)

    It seems to like to read the Additional CSS area as prominent compared to the Child Theme CSS.

    Hi @kristinubute

    If your CSS changes are more prominent in the Additional CSS area, then it might be a good idea to continue adding your CSS code there.

    However, it’s important to note that the CSS in the child theme should ideally take precedence unless it is disabled by custom code.

    I hope this provides some clarity. Please let us know if you have any other questions!

    Thread Starter kristinubute

    (@kristinubute)

    HI, I have another client the same thing. If I change text in CSS in the Child Theme, then it is NOT reflected. But when I add CSS into the Theme/ Appearance/ Additional CSS it works.

    Why would that be ?

    Thanks

    Kristin

    Hi @kristinubute

    The issue you’re experiencing might be due to the loading order of the CSS files. The CSS in your child theme is loaded before the parent theme’s CSS, so the parent theme could overwrite any changes you make in the child theme.

    When you add CSS into Additional CSS, it is loaded last and, therefore, has the highest priority. This is why your changes appear when you add them there.

    To resolve this issue, ensure that your child theme’s CSS is loaded after the parent theme’s. You can do this by correctly enqueuing the child theme’s stylesheet in your functions.php file: https://gist.github.com/dividezigns/3381b7b2f0030a43cc9b1cbb197e3e23

    I hope this provides some clarity. Please let us know if you have any other questions!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Changing code in Child Theme or the Additional CSS in Appearance’ is closed to new replies.