1.利用浮动
<section class="layout float">
<style type="text/css">
.layout article div {
height: 100px;
}
.layout.float .left {
float: left;
width: 300px;
background: red;
}
.layout.float .right {
float: right;
width: 300px;
background: blue;
}
.layout.float .center {
background: yellow;
margin: 0 300px;
}
</style>
<article class="left-right-center">
<div class="left"></div>
<div class="right"></div>
<div class="center">
<h1>浮动解决方案</h1>
1.这是三栏布局的中间部分
2.这是三栏布局的中间部分
</div>
</article>
</section>
2.双飞翼布局
<section class="layout double">
<style type="text/css">
.layout article div {
height: 100px;
}
.layout.double .left-center-right {
overflow: hidden;
}
.layout.double .center {
width: 100%;
float: left;
background: yellow;