Page Background Color & Image (5 posts)

  1. cricket346
    Posted 5 years ago #

    Ok, this used to be easy to do with CSS. Now it has become difficult (probably not, but it confounds me). WP seems to have added a Custom Background section to their admin. Now, I cannot use my own CSS to specify a background color and image. Does anyone know how I can override the built-in WP Custom Background code?
    I used to be able to put

    body {
    	background-image: url(images/my_image.jpg);
    	background-position: center bottom;
    	background-repeat: no-repeat;
    	color: #000;

    But that doesn't do anything now in the Twenty Eleven template.
    Thanks in advance.

  2. zeaks
    Posted 5 years ago #

    In Twenty Eleven you can remove and clear the background in appearance > background. Once you do that, it will use whatever have set in your CSS.

    If you're creating a child theme, it will use whatever background image/color you have set in the CSS first, and only change if you tell it to.

    If you are set on overriding it, maybe adding !important to your css will do it. Not sure if that's the proper way though.

  3. cricket346
    Posted 5 years ago #

    Yes, I already did that. I also tried !important, however, it does not apply it properly. It will not add the color I specify. It will show the image, but ignores position bottom.

  4. zeaks
    Posted 5 years ago #

    Do you have a link to your page?

  5. cricket346
    Posted 5 years ago #

    I am figuring it out. It seems to require lots of !important tags and deleting of other css throughout the style.css. This twenty eleven stylesheet seems quite a mess. Not organized very well.

Topic Closed

This topic has been closed to new replies.

About this Topic