我只是模态:
$('#report').click(function(e){
$('#report_window').modal({
autoResize: true
});
return false;
});
和CSS:
#basic-modal-content {display:none;}
#simplemodal-overlay {
background-color:#000;
}
#simplemodal-container {
width: 600px;
height: auto !important;
top: 25% !important;
color: #bbb;
background-color: #fff;
border: 4px solid #eee;
padding: 12px;
/* for IE */
min-height:auto !important;
}
#simplemodal-container .simplemodal-data {padding:8px;}
#simplemodal-container a.modalCloseImg {background:url('../images/close.png') no-repeat; width:25px; height:29px; display:inline; z-index:3200; position:absolute; top:-15px; right:-16px; cursor:pointer;}
#simplemodal-container p {
color: #333;
font-size: 15px;
}
#simplemodal-container h3 {
color: #6666cc;
margin: 0px 0px 15px 0px;
}
对于Opera,FF,Chrome来说还可以,但是在IE上,模态高度始终为100%:(可以确定的最高边距(始终为25%),但是高度为最低...
最佳答案
您是否尝试过声明模式容器的位置?
position:absolute;
关于javascript - CSS-IE上的模态,自动高度?,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/28531652/