0

我正在使用 CSS 灯箱来显示通讯订阅功能。弹出窗口在除 IE 6 之外的所有浏览器中都能正常工作 - black_overlay - 背景颜色和不透明度不显示。

下面列出了我用于弹出显示的样式:

    .black_overlay{
        position: relative;
        top: 0px;
        left: 0px;
        width: 400px;
        height: 300px;
       min-height: 900px;
       height:auto !important;
        background-color: black;
        z-index:1001;
        -moz-opacity: 0.8;
        opacity:.80;
        filter: alpha(opacity=80); }

         .white_content {
        display:none;
        position: relative;
        top: 100px;
        left: 50px;
        width: 500px;
        height: 300px;
        min-height: 400px;
        height:auto !important;
        padding: 16px;
        border: 16px solid #999;
        background-color: white;
        z-index:1002;
        overflow: auto;
    }

还有一项:我正在使用 javascript 来显示一个弹出窗口。这个显示块可以在 IE 6 上运行吗?我无法在 IE6 上进行测试,因为我的系统中安装了 IE8。

document.getElementById('newsletter').style.display='block';

       <div id="newsletter" class="white_content"></div>
      <div id="fade" class="black_overlay" ></div>
4

1 回答 1

1

对于 ie6 中的叠加层,您需要将15x15px透明 gif 作为叠加层,并且需要在背景中重复作为叠加层,而不是适合您的不透明度 :-)。对于 ie6 中的 hack,您需要添加 hack。例如height:20x;这个东西只适用于ie6

于 2012-08-30T17:48:16.493 回答