[Resolved] Child Theme , Custom CSS best practices

Home Forums Support [Resolved] Child Theme , Custom CSS best practices

Home Forums Support Child Theme , Custom CSS best practices

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #152726
    Suzanne

    I’ve been humming along on customizing my standard GeneratePress site using the Custom CSS plugin and it looks wonderful. Now I need to make some php function additions. I’ve installed the blank child theme and I’m hoping for some guidance on how to work with my existing Custom CSS file and now the Child theme css file. Should I copy and paste the Custom css file contents into the Child Theme css file and move ahead working with only the Child Theme css file? I really don’t want to work with two css files.

    #152748
    Tom
    Lead Developer
    Lead Developer

    Hi there,

    No need to add the exiting CSS into your child theme – just start adding your custom CSS in there and you’ll be good to go 🙂

    Let me know if you need more info.

    #152760
    Suzanne

    How/where to modify existing custom css? It’s located in the Custom css file, not the Child theme css file. The child theme css file is blank.

    #152762
    Tom
    Lead Developer
    Lead Developer

    The child theme CSS file is supposed to come blank, then you add your custom CSS to it which overwrites the parent CSS.

    The existing parent theme CSS should never be touched/copied/changed.

    All new CSS that you write should go in your blank child theme.

    Let me know if that makes more sense or not 🙂

    #152766
    Suzanne

    I know not to modify parent css theme. I set up a custom css file with the plugin you recommended Simple Custom css and have been working with that BEFORE I set up the child theme.

    Set up the child theme, now I have the Custom css file, and the Generatepress child theme css file.

    Is there a way for me to upload an image?

    #152830
    Tom
    Lead Developer
    Lead Developer

    In that case, you can choose whether to put your CSS into the plugin or child theme – no point in having both really.

    You can use the “Media” area in your Dashboard to upload images.

    #152832
    Suzanne

    Thanks for getting back to me. So as to my original question:
    Should I copy and paste the Custom css file contents into the Child Theme css file and move ahead working with only the Child Theme css file?

    This question”Is there a way for me to upload an image?” was in reference to uploading an image to the Support panel here so I could show you visually what I am describing.

    #152904
    Tom
    Lead Developer
    Lead Developer

    Ah, I understand 🙂

    Yes, I would move the CSS you’ve added to the custom CSS plugin to your child theme – that way you don’t need to depend on a plugin.

Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.