CSS for Child theme

I can't seem to get my custom CSS to work in the child theme.

I have set it to "default" and renamed the child-sample-style.css to child-style.css (and moved it to the root of the bp-fun-child folder with style.css, which it does not say to do but it doesn't show up otherwise.

At present I am trying to acomplish a very simple css change.

I want to change this

#top-header .top-h {
  padding: 2%;
  width: 96%;
  margin: 0px;
  float: left;
  background: #FFFFFF;
}

to this

#top-header .top-h {
  padding: 2%;
  width: 96%;
  margin: 0px;
  float: left;
}

Note the lack of the background color. I tried it in the style.css file and the child-style.css and get nothing...

Also, I'd like to mention that one of the reasons I joined was that all the themes are supposed "well documented" and "come with a manual" which I rarely see in any of your themes.

  • Patrick
    • Support Monkey

    Hi again Delirium Comics,

    The child-style.css file must reside in the _inc/css folder like so: wp-content/themes/buddypress-fun-child/_inc/css/child-style.css.

    The reason your background color adjustment is not being seen on your site is this: css is an acronym for Cascading Style Sheets. That means that your browser will look first in the stylesheet farthest down the line, then work its way up the queue.

    If you simply remove a style rule from your child-style.css, and the browser finds that rule in a stylesheet farther up the queue, that rule will be applied.

    You must therefore declare a new rule like so:
    #top-header .top-h {
    padding: 2%;
    width: 96%;
    margin: 0px;
    float: left;
    background: transparent;
    }

    Also, the WPMUdev manual, chock full of good stuff, is here: https://premium.wpmudev.org/wpmu-manual/

    Hope this helps! :slight_smile:

  • VC Nickels
    • Site Builder, Child of Zeus

    The child-style.css file must reside in the _inc/css folder like so: wp-content/themes/buddypress-fun-child/_inc/css/child-style.css.

    umm... OK. I'll put it back in the _inc/css/ folder and see what happens. I was being lazy and trying to use the WordPress editor like you would normally with a child theme (including yours) do but I guess that doesn't work for this theme, which is odd.

    Also, the WPMUdev manual, chock full of good stuff, is here: https://premium.wpmudev.org/wpmu-manual/

    I've gone through the various WPMU manuals, and they have been useful. I've been using WordPress off and on for about 6 years but I'm still sorting out Multisite, BuddyPress and bbPress. Regardless, several of your videos and themes say that all your themes come with manuals which I though was a nice touch. Themes are not always intuitive and as it stands your individual theme documentation is pretty thin.

    I dig your plugins a lot though and that's the real reason I came anyway. I'd like to use your themes as well though since they all should work together with your plugins.

  • Patrick
    • Support Monkey

    @Delirium Comics

    Great news! If you need more help, don't hesitate to post again. Both the staff and other members are here to lend a hand when you need it. :slight_smile:

    @Joe

    Thanks for the points... I've now topped 500, and got a new cool badge to boot!

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.