jquery - 弹出窗口中的内容不显示在 IE 9 中

标签 jquery html css internet-explorer-9 bpopup

div 中的内容在 Ie9 中不显示。它在所有其他浏览器中显示?

<div id="element_to_pop_up2"   style="z-index:9999999">

    <a href="#" class="b-close">x</a>

     **There will be Delay with shipping this week.**
    </div>

   $(document).ready(function () {
       $('#element_to_pop_up2').bPopup({
              speed: 650,
              transition: 'slideIn'
       });
    });

最佳答案

看我的 fiddle http://jsfiddle.net/rYLu8/1/我乱七八糟地复制了你的代码,并从 JS 复制了代码(因为无法直接从 GitHub 提供)

$(document).ready(function () {
   $('#element_to_pop_up2').bPopup({
          speed: 650,
          transition: 'slideIn'
   });
});

它似乎在 FF、Chrome 和 IE9 上对我“有效”——但是我不会在任何情况下都将其描述为“正常工作”,因为它似乎只在您调整窗口大小时才使内容居中,而这并不有道理。

总而言之,我猜您的代码有问题,但我强烈建议您查看一些更好的东西(并且没有一些幼稚的标语),例如 http://twitter.github.io/bootstrap/javascript.html#modalshttp://jqueryui.com/dialog/ ,它们将更易于使用,跨浏览器更可靠,并且它们拥有庞大的社区,您可以询问是否遇到困难。

关于jquery - 弹出窗口中的内容不显示在 IE 9 中,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16553348/

相关文章:

javascript - 如何仅在用户打印时显示某些内容?

html - css - 内联元素忽略行高

css - float div 一个并排 - 2 列布局

html - CSS3 仅使用单个 DIV 创建此按钮

jquery - 使用 CSS bootstrap 的垂直导航栏

javascript - 如何检查是否创建了特定的 div 元素?

jquery - $.when 对于单个 $.Deferred 有何作用?

jquery - 无法将子元素附加到父 div

javascript - 导航栏事件标志未由 JavaScript 设置,手动设置时一切看起来都很好

html - 消除渲染阻塞资源(灯塔)