Jump to content
melissalove

Footer Background not Displaying

Recommended Posts

melissalove    0
melissalove

Hey & Happy New Year

 

I am trying to pull in a fixed dimension footer background with CSS.

Here is the site:

 

www.trulymadlykids.co.uk

Here is the code I am using:
#footer {
    background-image: url(http://www.trulymadlykids.co.uk/wp-content/uploads/2013/01/Footer-Background.jpg);
    background-repeat:no-repeat;
    background-attachment:fixed;
    background-position:center;
}

 

I have tried my own tweaks, Firebugged it, but nothing.

Any tips gratefully apppreciated.

Cheers

Melissa

Share this post


Link to post
Share on other sites
James B    436
James B

Hi Melissa,

 

Firstly, site looks great! However I can't see where the footer is on the page, have you hidden it until you get this sorted?

 

As the site is fixed width it will use a slightly different selector as per below. The footer will need to be unhidden for the css to show.

 

body.fixed_width #footer {
    background: none repeat scroll 0 0 transparent;
    margin: 0 auto;
}
  • Like 1

Kindly search the forum and read the documentation before posting. It will help you resolve many issues.

For CSS help be sure to check out W3Schools first and be sure to download FireBug for FireFox for troubleshooting.

James B

Share this post


Link to post
Share on other sites
melissalove    0
melissalove

Thank-you! I had the selector wrong. Forgot about the fixed width.

For anyone else, here is what works for me:

body.fixed_width #footer {
    background: url(http://myurl.jpg);
    margin: 0 auto;
}

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


×