CSS Z-Index IE 错误修复?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/458118/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Z-Index IE bug fix?
提问by damien535
Does anyone know of a working fix for the ie z-index bug? I have come across a few solutions but interested to see if anyone here knows of a better fix.
有谁知道 ie z-index 错误的有效修复程序?我遇到了一些解决方案,但有兴趣看看这里是否有人知道更好的解决方案。
Thanks!
谢谢!
采纳答案by StingyHyman
If you mean the problem of IE6 not respecting the z-index on select controls, then yes.
如果您的意思是 IE6 不尊重选择控件上的 z-index 的问题,那么是的。
There is also a few others. I think the best method is to inform the users that IE6 has been replaced and that they would be better off using IE7, FF, or another recent browser verison, or direct them to the MS article explaining the problem and their courses of action.
还有一些其他的。我认为最好的方法是通知用户 IE6 已被替换,他们最好使用 IE7、FF 或其他最近的浏览器版本,或者将他们引导至解释问题和他们的行动方案的 MS 文章。
You may not have this luxury, in which case, you should try using the select free or a few others that turn up in google results. It sucks, but you will have to try one of them.
您可能没有这种奢侈,在这种情况下,您应该尝试使用 select free 或其他一些出现在 google 结果中的选项。这很糟糕,但你必须尝试其中之一。
回答by StingyHyman
If your problem is about IE 6 select element z-index problem, and you happen to use jQuery for development, then you may try the convenient jQuery bgiframe pluginto solve it. :p
如果您的问题是关于IE 6 select element z-index问题,而您恰好使用jQuery进行开发,那么您可以尝试使用方便的jQuery bgiframe插件来解决它。:p
回答by Becca
I used the jQuery bgiframe pluginsuggested by Honesty, and added a conditional comment to keep it from loading for other browsers.
我使用了Honesty 建议的jQuery bgiframe 插件,并添加了条件注释以防止它加载到其他浏览器。
This posthas more helpful info on implementing it.
这篇文章有更多关于实施它的有用信息。
回答by nshaw
Depending upon what you are trying to do, there might not be an easy fix. Here is a good discussionof some of your options, including cases that are not easily handled.
根据您尝试执行的操作,可能没有简单的解决方法。这里很好地讨论了您的一些选择,包括不容易处理的情况。
回答by George
Make sure your browser is not in compatibility mode! I was at work, and IE automagically set my browser to "Display intranet sites in compatibility mode". I used the following meta-header to override this ridiculous setting:
确保您的浏览器未处于兼容模式!我正在工作,IE 自动将我的浏览器设置为“以兼容模式显示 Intranet 站点”。我使用以下元标题来覆盖这个荒谬的设置:
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8" />