views:

295

answers:

4

http://www.wilwaldon.com/crossing/page3.html

If you look at the page in IE7 there is an ungodly amount of space between the top paragraph and the bottom spotlight area. It works fine in all other browsers.

If you know of any tricks or hacks to prevent this I'd greatly appreciate this :)

Thank you!

A: 

Try getting it to validate first.

Pickle
A: 

This site may help you out with doing some conditional CSS to handle IE7:

David
A: 

if you set display:inline on your spotlight div it should render better in IE7...but that will break other browsers - so use the conditional css - or rewrite your style to be more compliant

Pete Amundson
+1  A: 

The reason you're getting all that space is because of all the top padding and margin you put on the #spotlight yourself. You seem to be adding all that space as a way of making enough room for the floats inside it. Don't do that. Make the div contain its floats by adding overflow: hidden to it. If that has unwanted side-effects, add the clearfix class to it, which is already in your CSS.

The reason you're seeing all that space in IE7 is because the #spotlight has a width, which is triggering layout. That causes it to contain its floats already, pushing all that top margin and padding up above it.

Oh, and don't use multiple id="spotlightbox". That's what classes are for. IDs must be unique. Use class="spotlightbox" instead.

mercator
Thank you, added classes instead of id's and it worked great. I am just hacking up this code from another developer so my brain wasn't working properly. Thanks a million!
wilwaldon