View Full Version : CSS Problem - content being pushed down by left navigation
directmarketingadvice
10th August 2009, 22:30
Hi guys,
I've got a site (don't want to share the domain) where I'm using CSS.
In firefox, it looks fine. However, in IE7, the left menu is in place, but the main content is pushed down below where it should be.
i.e. you have the menu in the correct place, opposite the menu is white space where the main text should be, below that is the text.
Anyone seen this sort of thing before?
If so, any ideas what normally causes this sort of problem?
Cheers,
Steve
Kev Jaques
10th August 2009, 23:29
stick in a temp border: solid 1px red; in both the divs to see their boundaries, most likely they're too wide hence one being below the other, you can then reset the width so they both align, they will most likely contain floats which is ok.
if you are not using a reset css file, might be a good idea to add one, then you are playing with all browsers from a clean set, this approach adds a little bit more work to restyle defaults but far better results.
FireFleur
10th August 2009, 23:35
It is a whole host of possible problems, so the border trick or background-color is the start off point as Kew Jacques points out.
Often though, it is the box model which differs slightly between Geko (Mozilla) and IE, that pushes a few pixels out and drops the box. In that case you just make the box a little smaller or a lot smaller first to see if it is that.
Kev Jaques
10th August 2009, 23:43
rofl are you pissed furefoor?
I don't do gardens ;) and no 'c' in surname ;)
FireFleur
10th August 2009, 23:49
:) That was quite a typo, I made you French Horticulture.
Cannot edit, so I will just correct: Kew Jacques should, of course, be Kev Jaques.
cmcp
10th August 2009, 23:56
It's pretty much going to be the box model.
Good advice with highlighting your div sections, it's always handy.
directmarketingadvice
11th August 2009, 07:26
You guys are stars.
It was, as you suspected, that the divs were too wide to fit in IE7.
I reduced the width of the main section by 50px and it fits fine.
Thanks for the pointers.
Cheers,
Steve
KM-Tiger
11th August 2009, 10:38
Phew!
You've got to get those front page ads in the right place if they are going to convert more than 18 a day.