【问题标题】:Forcing intranet users to view webpage in IE8 mode, not compatibility mode [duplicate]强制内网用户以IE8模式查看网页,而不是兼容模式[重复]
【发布时间】:2011-03-04 02:14:53
【问题描述】:

可能重复:
Override intranet compatibility mode IE8

虽然我指定了

 <meta http-equiv="X-UA-Compatible" content="IE=8" />

但是由于 IE 的“在兼容性视图中显示 Intranet 站点”设置,我的应用没有在 IE8 中查看,而是在兼容模式下查看。

有人知道有没有办法解决这个问题???

【问题讨论】:

标签: iis internet-explorer-8 http-headers ie8-compatibility-mode


【解决方案1】:

This 会帮助你。

if (window.navigator.appName == "Microsoft Internet Explorer"){
    // This is an IE browser. What mode is the engine in?
    if (document.documentMode==8) // IE8
    {
        alert('IE8')
    }
    else
    {
        alert('Not IE8 or in Compatibilty mode');
    }
}

根据错误状态(不是 IE8 或兼容模式),您可以将用户重定向到说明如何设置他/她的浏览器的页面。 我想知道是否有一个自动脚本可以做到这一点?

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2011-01-31
    • 1970-01-01
    • 2010-11-04
    • 2012-07-30
    • 2010-11-22
    • 2010-10-15
    • 1970-01-01
    • 2011-05-04
    相关资源
    最近更新 更多