Go Back   CodingForums.com > :: Client side development > HTML & CSS

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 11-02-2009, 06:01 PM   PM User | #1
nickburrett
New Coder

 
Join Date: Jun 2009
Posts: 63
Thanks: 22
Thanked 0 Times in 0 Posts
nickburrett is an unknown quantity at this point
Missing backgroud-color in Firefox

Hi

I'm helping out a friend with his website but I'm having trouble understanding why there the background color from the #wrapper is missing in Firefox.

Can anyone point me in the right direction?

http://www.bumble-b-roadshow.co.uk/

Thanks in advance
Cheers
Nick
nickburrett is offline   Reply With Quote
Old 11-02-2009, 06:14 PM   PM User | #2
Excavator
Master Coder


 
Excavator's Avatar
 
Join Date: Dec 2006
Location: Alaska
Posts: 9,410
Thanks: 22
Thanked 1,765 Times in 1,749 Posts
Excavator has a spectacular aura aboutExcavator has a spectacular aura aboutExcavator has a spectacular aura about
Hello nickburrett,
You need to clear your floats.
Make your CSS look like this:
Code:
#wrapper { margin: auto; width: 760px; text-align: left; background-color: #FFFFFF; overflow:auto;}
Here's a site that explains how that works.
__________________
Validate often DURING development - Use it like a splelchecker | Debug during Development |Write it for FireFox, ignore IE
Use the right DocType | Validate your markup | Validate your CSS | Why validating is good | Why tables are bad
Excavator is offline   Reply With Quote
Old 11-02-2009, 06:14 PM   PM User | #3
Rowsdower!
Senior Coder

 
Rowsdower!'s Avatar
 
Join Date: Oct 2008
Location: Some say it's everything.
Posts: 2,007
Thanks: 5
Thanked 395 Times in 388 Posts
Rowsdower! has a spectacular aura aboutRowsdower! has a spectacular aura aboutRowsdower! has a spectacular aura about
Quote:
Originally Posted by nickburrett View Post
Hi

I'm helping out a friend with his website but I'm having trouble understanding why there the background color from the #wrapper is missing in Firefox.

Can anyone point me in the right direction?

http://www.bumble-b-roadshow.co.uk/

Thanks in advance
Cheers
Nick
Add overflow:auto; to the CSS for #wrapper


The problem was that the content and menu divs were both floated so no height beyond the start of these elements was calculated for the wrapper. To fix this you could either insert an element below #wrapper with clear:both; or else you could apply overflow:auto; to the wrapper, as I am suggesting. Both methods have the same effect but this one avoids extra HTML markup in the page.
__________________
The object of opening the mind, as of opening the mouth, is to shut it again on something solid. –G.K. Chesterton
See Mediocrity in its Infancy
It's usually a good idea to start out with this at the VERY TOP of your CSS: * {border:0;margin:0;padding:0;}
Seek and you shall find... basically:
validate your markup | view your page cross-browser/cross-platform | free web tutorials | free hosting
Rowsdower! is offline   Reply With Quote
Reply

Bookmarks

Tags
css, firefox

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 12:32 AM.


Advertisement
Log in to turn off these ads.