• Hi,

    Do you know how to solve either of the 2 following problems?

    I want to change my exterior, gray background color to f2f2f2 to match the rest of my website. But, when I insert it in…

    style.css
    body
    background

    …it doesn’t work. Any ideas why?

    Do you know how to move the header image to the top of the screen, so that no gray background shows?

    Thanks for your help,

    Greg

Viewing 2 replies - 1 through 2 (of 2 total)
  • Without seeing your page, I can’t say for sure, but it could be a few different things. First, it is possible that there is another place later on in the style sheet that specifies a background color, and it’s over-riding what you specified. It could also be that there is a div inside the body that hides the body background from being shown. The first possibility is more likely. There is also the possibility that there is a syntax error in your code. Here’s the proper code for changing the background color of the body:

    body{background-color: #f2f2f2;}

    There are also a few different things that could be causing the space above the header. It is probably the margin and/or padding on either the body, the image itself or a containing div. Try changing the margins/paddings of the elements involved to see what helps. For example:

    body{margin: 0; padding:0;}

    Thread Starter goodnews1

    (@goodnews1)

    Hi Alex,

    Thanks for taking the time to reply to my question! (Sorry I didn’t reply to you earlier, since I just found the time to try your suggestions.)

    Your advice solved the 2nd problem: The space is now deleted above the header image.

    However, I could not solve the first problem. My background color is still the default, light gray. But, I want to change it to an even lighter gray f2f2f2. You mentioned that there may be a div inside the background. Where should I look for that?

    Does anyone here know how to solve that background color problem?

    Also, in Firefox (but not I.E.) there’s a huge gap between my Text 1 widget at the top of the sidebar vs. my Pages/Categories/Recent Posts, etc. at the bottom of the sidebar. Does anyone here know how to solve that problem? Here is the blog: https://www.jesussaidfollowme.org/blog/

    Thank you,

    Greg

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Why Am I Having Trouble Changing the Background Color?’ is closed to new replies.