怪癖模式和IE8问题
我有一个非常奇怪的问题,仅涉及 IE8 + Windows Vista,错误非常奇怪,我将使用一些示例名称。
我有 2 个页面,page1.html
和 page2.html
,当打开这两个页面时直接输入地址,没有怪异模式。
当通过 _blank
链接(新窗口)打开 page2.html
时,它会以 Quirks 模式显示,这种情况仅发生在页面打开时就按照上面说的方法打开了。
我尝试
- 过从不同网站打开
page2.html
。 - 在
page1.html
和page2.html
上使用。
注意事项:
- 页面上的文档类型为
- DOCTYPE 上方有 NO 空格/XML 声明
- 如果在新选项卡中打开链接或一样的标签,没有问题。
这让我很困惑,它在 Windows7 上的 IE8 上运行得很好,在 Windows XP 上的 IE6 上也运行得很好。
更新:这不会发生在测试服务器上,只会发生在生产服务器上,那么服务器端是否有任何可能影响此问题的因素?
还尝试了 我认为这会强制它呈现为 IE-8,但可惜的是,它没有不工作。
I have a very strange issue regarding only IE8 + Windows Vista, the error is very strange, I'll use some example names.
I have 2 pages, page1.html
and page2.html
, when opening both typing the address directly, there is no quirks mode.
When page2.html
is opened via a _blank
link (new window), it is displayed in Quirks Mode, this ONLY happens when the page is opened the way mentioned above.
Things I've tried
- Opening
page2.html
from different websites. - Using
<!DOCTYPE html>
onpage1.html
andpage2.html
.
Things to note:
- The doctype on the pages is
<!DOCTYPE html>
- There is NO whitespace / XML declaration above the DOCTYPE
- If the link is opened in a new tab or same tab, there is no problem.
This just baffles me, it works fine from IE8 on Windows7, and also works fine with IE6 on Windows XP.
Update: This doesn't happen on the test server, only on the production server, so is there anything server side that could affect this?
Also tried <meta http-equiv="X-UA-Compatible" content="IE=8" >
which I thought would force it to render as IE-8, but alas, it doesn't work.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
单击“工具”(如果没有菜单栏来启用它,请右键单击浏览器窗口顶部)->兼容性视图设置->检查您的 Intranet 区域是否设置为在兼容性视图中显示。
Click Tools (right click the top of the browser window if you don't have a menu bar to enable it) -> Compatibility View Settings -> check if your intranet zone is set to display in compatibility view.
这是一个相当简单的问题,与页面代码错误无关,是 IE 插件造成的,感谢帮助。
This was a rather straight forward problem, it was nothing to do with the page having bad code, it was an IE addon that caused it, thanks for help.