IE7 and 8 formatting issues


Can anyone help me find out why this page floats to the left in IE7/8?

How can i fix this?


Silly me :slight_smile:

Thanks Stomme poes, i have got it working.


Hi Billy

this is an easy one, I believe.

Your doctype isn’t complete, which is enough of an excuse for all IE’s to act like IE5 : )

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

Even though browsers don’t actually use the referrer url, you need to have it for the browser to assume Standards Mode (exception is when using the HTML5 doctype).

Copy the HTML4 doctype from this page: You see, you’re missing that second line.

I really do copy and paste from there… less chance of a typo screwing stuff up (and I’ve had a typo, an extra space between I think the words DTD and HTML or something, and that was enough to trigger Almost Standards Mode in Firefox!).

And, new page? Use Strict : )