background-color
.one{
width:100px;
height:100px;
background:#cc0000;
float:left;
}
.two{
width:100px;
height:100px;
background: #0066ff;
float:left;
}
.three{
width:100px;
height:100px;
background:#66ff00;
float:left;
clear:left;
}
.four{
width:100px;
height:100px;
background:#ffff00;
float:left;
}
分号没加
而且你的background:#000000 后面缺少;号
补充一下,我将float:left跟clear:left两个指令去掉之后,就变成这样:
反正就是一定不能加float:left,一加上颜色就不见了
Copyright © 2019- axer.cn 版权所有 湘ICP备2023022495号-12
违法及侵权请联系:TEL:199 18 7713 E-MAIL:2724546146@qq.com
本站由北京市万商天勤律师事务所王兴未律师提供法律服务