Lily
Lily

Reputation: 1

fix for a gap in IE for an image

I have read the answers posted for this issue and tried them all, but still have the gap. See link to the site I am working on http://www.poolboy.ca/. It's the gap between the top of the pool and the menu bar. Please help!

Upvotes: 0

Views: 223

Answers (2)

Louise McMahon
Louise McMahon

Reputation: 2145

add to your css i cant promise anything but this will set all boxes to have 0px margin padding and border by default this is something i can not fathom about ie but it normally fixes it

* {
    padding: 0px;
    margin: 0px;
    border: 0px;
}

Upvotes: 0

thirtydot
thirtydot

Reputation: 228182

There's a really easy fix here.

Your doctype (first line) is currently this:

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

That doctype triggers Quirks Mode in IE.

If you change your doctype to this:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">

IE will be in Standards Mode instead, and your gap will magically disappear.

You could instead just use the HTML5 doctype, which is much shorter:

<!DOCTYPE html>

Upvotes: 4

Related Questions