繁体   English   中英

IE11儿童 <div> 标签在页面底部溢出

[英]IE11 child <div> tag overflowing at the bottom of the page

我有一个父<div>标记,它是子<div>标记。

<div>标记的高度是动态的,并取决于某些逻辑。

<div>标记的高度也应随子<div>标记的高度而变化,这在诸如Chrome,Firefox和Opera的浏览器中会发生,但在IE11不会发生。 这使得UI看起来像子<div>标记超出了页面底部的父<div>标记。

我的问题是-有没有办法确保子<div>标记保持在父<div>标记的边界内?

更新:添加CSS ...

.child {
    background: none repeat scroll 0 0 #F6F6F6;
    border: 1px solid #CCCCCC;
    border-bottom: 1px solid #CCCCCC;
    border-bottom-right-radius: 6px;
    border-bottom-left-radius: 6px;
    border-right: 1px solid #CCCCCC;
    border-top: 1px solid #CCCCCC;
    border-top-left-radius: 6px;
    border-top-right-radius: 6px;
    min-height: 749px;
    background-color: white;
    display:table;
    float:right;
    min-width: 900px;
    position:absolute;
    overflow: visible;
    height:100%;
}

.parent {
    overflow: visible;
    min-height: 100%;
    height: 100%;
    padding: 13px 25px 75px 25px;
    min-width: 900px;
}

将.parent高度设置为自动而不是100%,即:

.parent {
    overflow: visible;
    min-height: 100%;
    height: auto;
    padding: 13px 25px 75px 25px;
    min-width: 900px;
}

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM