【发布时间】:2015-06-12 09:58:47
【问题描述】:
我尝试在 DIV 上设置一个垂直滚动条以缩短高度。 它适用于 Chrome 和 IE 10(没有尝试其他)。 但是高度太短时,Firefox 不显示垂直滚动条。
有没有办法让Firefox即使高度很短也显示垂直滚动条?
div.title{
position: absolute;
top: 0px;
height: 97px;
width:100%;
}
body{
margin: 0;
}
div.tableHeader{
position: absolute;
top: 98px;
height: 28px;
overflow-y: scroll;
width:100%;
}
<body>
<div class="title">
<h1> Demo how to set vertical scroll bar</h1>
</div>
<div class="tableHeader">
<b>test vertical scroll bar, please check right side vertical scroll bar</b>
</div>
</body>
【问题讨论】:
标签: css firefox height vertical-scrolling