WordPress.org

Ready to get started?Download WordPress

Forums

Socialize Lite
Unable to display editted css code (12 posts)

  1. kpatel18
    Member
    Posted 1 month ago #

    Hi

    I'm trying to edit the css code, i know the css code i've written is correct as i've tested it via other sites, however when i add it to the css file for your theme it doesn't display or change anything. Even when i written css for a simple background change. The website i'm in the process of developing is http://kyn.karamsadsamaj.co.uk/ which is a subdomain. Any advice on what i can do to solve this problem would be appreciated.

  2. stephencottontail
    Member
    Posted 1 month ago #

    Can you post an example of what CSS code isn't working?

  3. kpatel18
    Member
    Posted 1 month ago #

    thanks for the reply. Generally everything i can't change any css at all.
    I've looked to make sure I'm using the correct class and id names via 'Inspect Element' and cross checked them with the style sheet just to make sure that they are on there.

    for example i used Style builder via Inspect Element and entered in some css code ' header#header{ background-color: red;}' which would change the top part background to red and it worked however on there when i placed that code onto the style sheet on wordpress nothing happened, it didn't change.

  4. stephencottontail
    Member
    Posted 1 month ago #

    Where did you place that code? Also, you may need to force a browser refresh (check your browser's documentation) or temporarily disable any caching plugins to see any changes to your site.

  5. kpatel18
    Member
    Posted 1 month ago #

    i placed it at different places on the style sheet. i've tried to use a child theme for it but it didn't work either. i'm not sure if i'm doing something wrong or not? in your view where exactly would be the best place to the css.

  6. stephencottontail
    Member
    Posted 1 month ago #

    You shouldn't edit the theme files directly, because those changes will be lost whenever the theme is updated. Instead, you should either use a child theme or a custom CSS plugin. I looked at your site and I don't see the header#header{ background-color: red;} anywhere in the code. Did you try forcing a browser refresh?

  7. kpatel18
    Member
    Posted 1 month ago #

    I know but i wanted to test it to see if it works or not. i normally use a child theme. I've just re-done the child theme and its still not working.

    You wouldn't be able to see the header#header{ background-color: red;} as the css isn't showing it, if you look at the child style sheet it shows it empty even after i added this 'header#header{ background-color: yellow;}'.
    I've also did the force refresh and no luck.

  8. stephencottontail
    Member
    Posted 1 month ago #

    How are you editing your child theme's stylesheet? Do you have any errors in your server's logs?

  9. kpatel18
    Member
    Posted 1 month ago #

    I'm editing it via the Appearance -> Editor.

  10. esmi
    Forum Moderator
    Posted 1 month ago #

    Do not edit the theme itself. First create a child theme for your changes. Or install a custom CSS plugin.

  11. stephencottontail
    Member
    Posted 1 month ago #

    Do you get any errors when you edit the stylesheet?

  12. kpatel18
    Member
    Posted 1 month ago #

    No errors where being display but i just found jetpack plugin and used that and at the moment its allowing me to edit the css.

    esmi - i did create a child one and i still go the error.

    Thanks, stephencottontail for all your help and advice. thanks esmi as well.

Reply

You must log in to post.

About this Theme

About this Topic

Tags

No tags yet.