【问题标题】:html popup background is overlapping with background in mobile devicehtml弹出背景与移动设备中的背景重叠
【发布时间】:2018-03-13 20:18:23
【问题描述】:

我为主页的菜单部分创建了一个弹出窗口。当您滚动页面时,您可以在预订按钮下方看到菜单部分。弹出窗口在桌面上正常工作。当我在移动设备上打开同一页面并单击菜单时,弹出窗口与背景重叠。

我找不到错误。当我在桌面上打开页面时,它会完美打开。我希望页面在移动设备上的打开方式与在桌面设备上一样

网址: https://theparlour21.se/

以下是我用来创建模态的 CSS:

.modal {
    display: none;
    position: fixed;
    z-index: 1;
    padding-top: 100px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgb(0,0,0);
    background-color: #000;
}
.modal-content {
    background-color: #000 !important;
    color: #d4d2d2 !important;
    border: 1px solid #451d22!important;
    padding: 0 20px;
    overflow-y: scroll;
    overflow-x: hidden;
    height: 560px;
    overflow: auto;
    background-color: #000;
    border-radius: 0px !important;
}

【问题讨论】:

    标签: html css modal-dialog


    【解决方案1】:

    在您的.modal class 中使用z-index:99999; 属性

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2013-03-26
      • 2018-08-19
      • 2017-07-18
      • 2014-09-10
      相关资源
      最近更新 更多