width:33.33%。三个用25%,50%,25%不能占满窗口
比如我把div设置成border:1px solid red;
.left .middle .right分别设置成width:25%,weidth:50%,width:25%
按照视频中的样式来写:
<html> <head> <style type="text/css"> div {text-align:center;font-size:30px; border:1px solid red;} .left {width:25%;height:200px; float:left;} .middle {width:50%; height:200px; float:left;} .right {width:25%; height:200px; float:right;} </style> </head> <body> <div class="left">left</div> <div class="middle">middle</div> <div class="right">right</div> </body> </html>
最后打开却是这样的?分别设置三个的总和不能占满整个窗口吗?