gpt4 book ai didi

internet-explorer - 如何在 IE10 中通过 iframe 强制 Bootstrap 下拉菜单

转载 作者:行者123 更新时间:2023-12-04 07:44:27 24 4
gpt4 key购买 nike

这个问题在这里已经有了答案:





z-index does not work in Internet Explorer with pdf in iframe

(4 个回答)


2年前关闭。




我在 Bootstrap 上运行了一个简单的测试,发现了一个仅在 IE10 中出现的问题。

如果您有一个下拉菜单和一个 iframe,则单击该下拉菜单会在 iframe 下方对齐。我有一个例子here

我已经尝试过一百万种不同的 z-index 方法。我已经在所有浏览器中进行了测试,只有 IE10 似乎有问题。

虽然我知道 IE10 还没有出现在任何 Windows 机器上,但它即将到来,我不希望菜单失败......有什么想法吗?

最佳答案

引用 here .可能值得一试。

$(document).ready(function () {
$('iframe').each(function(){
var url = $(this).attr("src");
$(this).attr("src",url+"?wmode=transparent");
});
});

另外,我认为您需要添加 style="position:relative;"到iframe实现z-index。

关于internet-explorer - 如何在 IE10 中通过 iframe 强制 Bootstrap 下拉菜单,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15713069/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com