如何强制Iframe在IE = EmulateIE7中运行的父页面下运行IE = edge模式

时间:2014-09-02 16:29:08

标签: javascript asp.net internet-explorer iframe

我正在开发应用程序在IE = Emulated7上运行的内容(运行正常)但现在我必须添加一个iframe来加载外部应用程序(SPA应用程序)。如果我可以更改我父母的下一行,那么一切都会好起来的。页...

<meta runat="server" http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />

<meta  runat="server" http-equiv="X-UA-Compatible" content="IE=edge" />

但我不能,因为还有其他页面需要这个IE7模式。

我尝试将IE = edge添加到我的子页面,其中将找到iframe,但不起作用。

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <meta id="OtherAppCompatibilityMeta" runat="server" http-equiv="X-UA-Compatible"  content="IE=edge" />
     <script>
    console.log("Iframe document mode: " + document.documentMode);
     </script>
    <style type="text/css"> 
       html, body{height: 100%;}
    </style>
</head>
<body>
<form id="form1" runat="server">
    <div style="height: 100%; width: 100%;">
      <iframe id="myId" runat="server" allowfullscreen="true"  style="position: absolute;height: 100%; width: 100%;border:0px"> </iframe>  
    </div>
</form>

从标题部分,document.documentMode的输出是:&#34; iframe文档模式:11&#34;,所以这对我来说很奇怪。 正如我之前所说,一切都应该更容易,我可以改变父母&#34;要使用iframe文档模式的页面:11但我不能

0 个答案:

没有答案