No replies
thepineapplehead
thepineapplehead's picture
Offline
Guru
Milton Keynes
Last seen: 11 weeks 1 day ago
Milton Keynes
Timezone: GMT+1
Joined: 2004-06-30
Posts: 9668
Points: 801

You will often see the moderators of this forum constantly going on about DTDs and Doctypes, and their completeness. We don't do this for a laugh, Doctypes are important.

IE has two rendering modes - Quirks mode and Strict mode. In Quirks mode, IE renders the page however it feels like on that particular day. You will notice problems with your CSS layouts that wouldn't appear in Strict Mode.

To enable Strict Mode you must use a COMPLETE DTD.

Please, ensure you have a complete and correct doctype before posting a question, as it cans solve many problems, and saves us having to waste time forcing people to use them before getting on to their problem.

ALA Doctypes

DOCTYPES THAT WORK
This one is the HTML5 doctype that is recognised by all modern browsers, is valid, renders in strict mode and is easy to remember.

<!DOCTYPE HTML>

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

XHTML 1.0 strict doctype
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

Verschwindende wrote:
  • CSS doesn't make pies