小米首页布局分解(4)

原创 2018-12-06 19:38:33 247
摘要:<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <link rel="shortcut icon" type="image/x-icon" href="sta
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<link rel="shortcut icon" type="image/x-icon" href="static/img/footlogo.png">
<link rel="stylesheet" type="text/css" href="static/font-awesome/css/font-awesome.css">
<link rel="stylesheet" type="text/css" href="static/css/style.css">
<title>小米商城</title>
</head>
<body>
<!-- 头部  header -->
<div>
<div></div>
</div>
<!-- 内容  content -->
<div>
<div></div>
<div>
<div></div>
<div></div>
</div>
<div></div>
<div>
<div></div>
<div style="background: url(static/img/midAD1.jpg);margin-right:12px;"></div>
<div style="background: url(static/img/midAD2.jpg);margin-right:14px;"></div>
<div style="background: url(static/img/midAD3.jpg);"></div>
</div>
<div></div>
<!-- 小米闪购 -->
<div>
<h1>小米闪购</h1>
<div style="margin-right: 12.7px;border-top: 1px solid red;"></div>
<div style="margin-right: 12.7px; border-top:1px solid yellow;"></div>
<div style="margin-right: 12.7px; border-top:1px solid green;"></div>
<div style="margin-right: 12.7px; border-top:1px solid blue;"></div>
<div style="border-top:1px solid red;"></div>
</div>
<div></div>
<div style="background: url(static/img/longAD1.jpg);"></div>
<div>手机</div>
<div>
<div></div>
<div>
<div style="margin:0px 12.7px 0px 0px;"></div>
<div style="margin:0px 12.7px 0px 0px;"></div>
<div style="margin:0px 12.7px 0px 0px;"></div>
<div></div>
<div style="margin:14px 12.7px 0px 0px;"></div>
<div style="margin:14px 12.7px 0px 0px;"></div>
<div style="margin:14px 12.7px 0px 0px;"></div>
<div style="margin-top: 14px;"></div>
</div>
</div>
<div></div>
<div style="background: url(static/img/longAD2.jpg);"></div>
<div>智能</div>
<div>
<div style="margin:0px 12.7px 0px 0px; background: url(static/img/buy/智能AD1.jpg);"></div>
<div style="margin:0px 12.7px 0px 0px;"></div>
<div style="margin:0px 12.7px 0px 0px;"></div>
<div style="margin:0px 12.7px 0px 0px;"></div>
<div></div>
<div style="margin:0px 12.7px 0px 0px; margin-top: 14px; background: url(static/img/buy/智能AD2.jpg)"></div>
<div style="margin:0px 12.7px 0px 0px; margin-top: 14px;"></div>
<div style="margin:0px 12.7px 0px 0px; margin-top: 14px;"></div>
<div style="margin:0px 12.7px 0px 0px; margin-top: 14px;"></div>
<div style="margin-top: 14px;">
<div></div>
<div style="margin-top: 10px;"></div>
</div>
</div>
<div></div>
<div style="background: url(static/img/longAD3.jpg);"></div>
<div>家电</div>
<div>
<div style="margin:0px 12.7px 0px 0px; background: url(static/img/buy/家电AD1.jpg);"></div>
<div style="margin:0px 12.7px 0px 0px;"></div>
<div style="margin:0px 12.7px 0px 0px;"></div>
<div style="margin:0px 12.7px 0px 0px;"></div>
<div></div>
<div style="margin:0px 12.7px 0px 0px; margin-top: 14px; background: url(static/img/buy/家电AD2.jpg)"></div>
<div style="margin:0px 12.7px 0px 0px; margin-top: 14px;"></div>
<div style="margin:0px 12.7px 0px 0px; margin-top: 14px;"></div>
<div style="margin:0px 12.7px 0px 0px; margin-top: 14px;"></div>
<div style="margin-top: 14px;">
<div></div>
<div style="margin-top: 10px;"></div>
</div>
</div>
<div></div>
<div style="background: url(static/img/longAD4.jpg);"></div>
<div class=""></div>
</div>
<!-- 页脚  footer-->
<div>
<div>网页底部</div>
</div>
</body>
</html>
*{padding: 0px;margin: 0px;}
.clear{clear: both;}
li {list-style: none;}
.fl{float: left;}
a{text-decoration: none;color: #ccc;cursor: pointer;}
/*头部样式*/
.header{background: #333;width: 100%;height: 40px;}

/*主体样式*/
/*父级给了宽度,一般让子级自己撑开所以content不设高度*/
.content{width: 1226px;margin: 0px auto;}
.content_menu{background: #ccc;height: 90px;margin:10px auto;}
.content_pic{margin:10px auto;}
.content_picl{width: 246px;height: 480px;background: #ccc;height: 480px;float: left;}
.content_picf{width: 980px;height: 480px; background: blue;float: left;}
.contentpic_ul{height: 170px;margin:10px auto;}
.contentpic_ul_1{width: 235px;background: #5F5750;height: 170px;margin-right: 13px;float: left;}
.contentpic_ul_0{width: 317px;height: 170px;float: left;}
/*小米闪购*/
.contentshop{height: 280px;margin:10px auto;}
.contentshop_1{width: 235px;height:340px;background: #ccc;float: left;}


.contentimg{background: #ccc;height: 100px;margin:10px auto;}
.contentul{background: #ccc;height: 80px;margin:10px auto;}
.contentphone{margin:10px auto;}
.contentphone_l{height: 614px;width: 234px;background: url('../img/buy/手机AD.jpg');float: left;margin-right: 12px;}
.contentphone_r{height: 614px;width: 980px;float: left;}
.contentphone_r div{width: 235px;height: 300px;float: left;background: #ccc;}
.contentphone_0,.contentphone_1{width: 235px;height: 300px;float: left;background: #ccc;}
.contentphone_t,.contentphone_b{width: 235px;height: 145px;background:#ccc;}
/*页脚样式*/
.footer{background: #ccc;width: 1226px;height: 100px;margin: 10px auto;}


发布手记

热门词条