1

Please look at this link - http://sklepylaserowe.test.dih.pl/. It displays well in Firefox, Chrome and Opera - but it's messed up in Internet Explorer (8 and 9). What could be a reason of it? (From list "Wybierz województwo", please select "śląskie", click "Dalej >>", and click on link that appears, to hide that overlay window)

Many basic CSS commands don't work, like:

margin:0 auto;
2
  • margin:0 auto isn't supported by IE :(
    – silentw
    Jul 10, 2012 at 13:53
  • 2
    @silentw - It isn't supported by IE 5.5 and earlier. It is supported by IE 6 and newer (but Quirks mode emulates that IE 5.5 bug).
    – Quentin
    Jul 10, 2012 at 13:54

2 Answers 2

9

You are failing to start the document with a Doctype, this triggers Quirks mode in which browsers emulate the bugs of their ancient ancestors.

Not supporting auto margins for centring is one of these bugs in IE (it was fixed in IE 6).

Validate your HTML. You cannot put any tags before the Doctype.

4
  • @Christoph - hence "failing to start" and the final paragraph rather than "missing" :)
    – Quentin
    Jul 10, 2012 at 13:56
  • @Christoph Which – from the point of view of MS IE – is the same as having none…
    – feeela
    Jul 10, 2012 at 13:56
  • @Quentin I misread;) You are right, I was wrong, how could a 5k User dare to correct a 165k Master. My Bad, plase forgive me o.O (:-D)
    – Christoph
    Jul 10, 2012 at 13:59
  • @Quentin Thanks for your answer. That seems to be the problem.
    – Irminsul
    Jul 10, 2012 at 14:09
1
<script src="http://maps.google.com/maps/api/js?sensor=false" type="text/javascript"></script>
<script type="text/javascript" src="js/jquery/jquery-1.4.4.min.js"></script>
<script type="text/javascript" src="js/geo.js"></script>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">

Change above code to

<!DOCTYPE html>
<html>
  <head>
    <script src="http://maps.google.com/maps/api/js?sensor=false" type="text/javascript"></script>
    <script type="text/javascript" src="js/jquery/jquery-1.4.4.min.js"></script>
    <script type="text/javascript" src="js/geo.js"></script>
    ...
2
  • 1
    That is still wrong. Script elements are not allowed outside the head/body elements.
    – Quentin
    Jul 10, 2012 at 13:57
  • I mentioned the order.. Edited the answer.. :) Jul 10, 2012 at 13:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.