internet-explorer-10 - IE 10 Beta - 打开其中包含框架集的窗口时,window.showModalDialog 会忽略dialogHeight 和dialogWidth

标签 internet-explorer-10

注意:仅 IE 10 Beta 版本才会出现此问题

场景: a.html有showModalDialog来打开b.html: window.showModalDialog(b.html, self, 'dialogHeight=800px;dialogWidth=900px');

b.html 中有框架集: <%@ Page Language="vb" AutoEventWireup="false" Codebehind="somefile.aspx.vb"> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Frameset//EN"> <HTML> <HEAD> Some Title </TITLE> </HEAD> <frameset rows="40px,*" border="0" frameSpacing="0" frameBorder="0"> <frame src="myfile.aspx" noresize height="100%" width="100%" scrolling="no"> </frameset> </HTML>

问题: 当我尝试使用 a.html 中的 window.showModalDialog 打开 b.html 时,尽管我给出了dialogHeight 和dialogWidth,但弹出窗口出现在一个小窗口中。仅 IE10 才会出现这种情况。我正在使用测试版。请帮忙。

最佳答案

我已经能够通过指定document compatibility mode来解决这个问题。在framesest页面中:

<meta http-equiv="x-ua-compatible" content="IE=7" >

关于internet-explorer-10 - IE 10 Beta - 打开其中包含框架集的窗口时,window.showModalDialog 会忽略dialogHeight 和dialogWidth,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12928745/

相关文章:

javascript - IE反转整个页面颜色

asp.net - "X-UA-Compatible IE=edge" header 不应该覆盖 IE10 中的 "Display intranet sites in Compatibility View"吗?

testing - 如何在Windows 7 的IE10 中测试网站?

css - 带有 colspan 边界的 td 在 ie10 怪癖模式下被破坏

css - 删除 IE1 0's "清除字段“某些输入上的 X 按钮?

internet-explorer - 2014 年 2 月测试的 Internet Explorer 版本 : browserstack, saucelabs、ghostLab、spoon 和其他工具

javascript - 在新选项卡中打开链接在 IE10 中不起作用

html - IE10 不支持空白 : pre-wrap?

javascript - ie10 中 clientHeight 的奇怪行为

jquery - IE 10 不显示模式。似乎是 jQuery 1.7.1 的动画问题