How can I show a message to IE6/IE7 browsers to upgrade to IE8 and have IE8 not show the IE7 warning?

前端 未结 13 977
醉话见心
醉话见心 2020-12-08 02:53

I want to only allow users with IE8 (not IE6, IE7) or another browser to access my site when logged in.

I followed: http://code.google.com/p/ie6-upgrade-warning/ But

13条回答
  •  盖世英雄少女心
    2020-12-08 03:50

    Depends on how you've coded your (X)HTML, but IE8 should use standards mode (not IE7 mode) if you have a strict doctype like:

    
    

    at the top of your HTML files.

    XHTML 1.0 Specs - Strictly Conforming Documents

    Here's a good post about how different doctypes/etc affect IE8's rendering mode: Understanding Compatibility Modes in Internet Explorer 8

提交回复
热议问题