1、左边固定,右边自动充满容器

<div>
<div class="div-left"></div>
<div class="div-right"></div>
</div>
.div-left{
width: 200px;height: 300px;
float: left;
background-color: #00b8ec;
}
.div-right{
position: relative;
height: 300px;
overflow: hidden; //最重要是这个,触发btc
background-color: #0bb20c;
}
网友评论