我的html页面中有两个分区,分别是css
<html>
<head>
#lowerone
{position:absolute; bottom:25px; right:25px; height:300px; width:300px;}
#upperone
{position:absolute; bottom:25px; right:25px; height:300px; width:300px; overflow:scroll;}
</head>
<body>
<div id="lowerone">
</div>
<div id="upperone">
<img src="/bg.3.jpg" />
</div>
</body>
</html>
但是上层div,即UPPERONE是uncrollabe .. 如何使其可滚动?
答案 0 :(得分:1)
使用2个绝对定位div的任何特定原因相互重叠?而且<style>
个标签丢失了...而滚动对我来说很有用..
答案 1 :(得分:0)
检查下面的代码,两个滚动工作,
<html>
<head>
<style>
#lowerone
{position:absolute; bottom:25px; right:25px; height:250px; width:300px;overflow:scroll;}
#upperone
{position:absolute; bottom:25px; left:25px; height:250px; width:300px; overflow:scroll;}
</style>
</head>
<body>
<div id="lowerone">
<img src="http://media.caranddriver.com/images/12q4/477956/2014-gmc-sierra-1500-photos-and-info-news-car-and-driver-photo-492039-s-450x274-1.jpg" />
</div>
<div id="upperone">
<img src="http://media.caranddriver.com/images/12q4/477956/2014-gmc-sierra-1500-photos-and-info-news-car-and-driver-photo-492039-s-450x274-1.jpg" />
</div>
</body>
</html>