男神9年前
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>弹性盒子</title>
<style type="text/css">
#dv{
width:450px;
height:400px;
background:#eee;
display:flex;
/*IE8 不支持弹性盒子*/
}
.div{
width:100px;
height:100px;
background:#f60;
margin:3px;
}
</style>
</head>
<body>
<div id="dv">
<div class="div">盒子1</div>
<div class="div">盒子2</div>
<div class="div">盒子3</div>
</div>
</body>
</html>
0