.top{width:100%;height:100px;background:grey;}
.main{height:300px;background:red;}
.left{ width:200px;height:300px;background:blue;margin-top:-300px;float:left;}
.right{height:300px;background:green;margin-left:210px ;}
.foot{width:100%;height:50px;background:orange;clear:both;}
.main{height:300px;background:red;}
.left{ width:200px;height:300px;background:blue;margin-top:-300px;float:left;}
.right{height:300px;background:green;margin-left:210px ;}
.foot{width:100%;height:50px;background:orange;clear:both;}
已采纳回答 / pirates5
.footer{width:960px;margin:0 auto; height:50px; background:#9F9; /*【任务4】*/clear:both}
2016-05-25
body{ margin:0; padding:0; font-size:30px; color:#000000;}
.top{ height:100px; background:#ccc;}
.left{ width:200px; height:500px; background:blue; position:absolute;}
.right{ margin-left:210px; height:500px; background:#9c9; position:relative;}
.footer{ height:50px; background:#f63;}
.top{ height:100px; background:#ccc;}
.left{ width:200px; height:500px; background:blue; position:absolute;}
.right{ margin-left:210px; height:500px; background:#9c9; position:relative;}
.footer{ height:50px; background:#f63;}
.top{background:#ccc;height:100px;}
.main{width:90%; margin:0 auto;background:red;position:relative;}
.left{ width:200px;background:blue;height:300px}
.right{position:absolute;left:210px;right:0;background:yellow;height:300px;}
.foot{background:orange;height:80px;}
.main{width:90%; margin:0 auto;background:red;position:relative;}
.left{ width:200px;background:blue;height:300px}
.right{position:absolute;left:210px;right:0;background:yellow;height:300px;}
.foot{background:orange;height:80px;}
最赞回答 / zyxmk
权值:如果同一元素设置了不同的css样式,浏览器会根据权值来判断使用哪种样式。一般来说:标签的权值为1;类选择符的权值为10,ID选择符的权值为100.eg:p{ font-size:12px} 权值为1 p span{font-size:14px } 权值为1+1=2. 所以p标签中的span标签中的内容的字体大小就为14px我知道的就这些了,欢迎纠正!
2016-05-23