【发布时间】:2011-07-12 14:12:39
【问题描述】:
在我的弹出窗口中,我已经固定了大小,如果内部内容较大,应该有一个垂直滚动条,它在 Firefox 中工作正常(虽然我只想要垂直滚动条)但在 IE 中不起作用(使用 IE 8 )。下面是图片。可能是什么问题?
我的 CSS 代码
#compareParentDiv
{
overflow-y: auto;
//overflow-x: hidden;
max-height: 380px;
width:100%
}
我的分区
$('#compareContent').empty();
$('<div id="compareParentDiv" width="100%">'+
'<table id="list2" cellspacing="0" cellpadding="0"></table>'+
'<div id="gridpager2"></div></div>')
.appendTo('#compareContent');
【问题讨论】:
-
您可以将“overflow: auto”设置为要添加滚动条的div。
-
@Michas:它适用于 chrome 和 firefox,但不适用于 IE
标签: javascript jquery css internet-explorer cross-browser