效果展示图:
代码展示:
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>问答1</title>
<style type="text/css">
.top{
width: 100%;
height: 80px;
background-color: #808080;
}
.main{
margin: 0 auto;
}
.banner{
width: 1030px;
height: 100px;
background-color: #808080;
margin: 0 auto;
margin-top: 15px;
}
.pink{
width: 1030px;
height: 400px;
background-color: #ffc0cb;
margin: 0 auto;
margin-top: 15px;
}
.item{
float: left;
width: 250px;
height: 400px;
background-color: #808080;
margin-right: 10px;
}
.bottom{
position:absolute;
bottom:0;
width: 100%;
height: 170px;
background-color: #808080;
}
</style>
</head>
<body>
<div class="top">top</div>
<div class="main">
<div class="banner">banner</div>
<div class="pink">
<div class="item">1</div>
<div class="item">2</div>
<div class="item">3</div>
<div class="item" style="margin-right:0;">4</div>
</div>
</div>
</div>
<div class="bottom">bottom</div>
</body>
</html>