html如何布置网页盒子位置之小米官网实例

<!DOCTYPE html>
<html >
	<head>
		<meta charset="UTF-8">
		<title></title>
		<link rel="stylesheet" href="font_4488588_9f0ii8zd7cf/iconfont.css">
		<style type="text/css">
		
		
		
		
		
		
		body{
			width: 1264.33px;
			height: 7435.5px;
			margin: 0px;
		}	
		.site-topbar {
			width: 1263.33px;
		    position: relative;
		    z-index: 30;
		    height: 40px;
		    font-size: 12px;
		    color: #b0b0b0;
		    background: #333;
		    
		}
		a.toper-cateage{
			color: #b0b0b0;
			font-size: 12px;
		    line-height: 40px;
		    display: inline-block;
		   	text-decoration: none;
		}	
		
			
			
			
			
			
			
			
			
			
			
			.site-header{
				width:1263.33px ;
				height: 100px;
				background-color: #DDDDDD;
				z-index: 20;
			}
			.container{
				width: 1226px;
				height: 100px;
    			margin-right: auto;
    			margin-left: auto;
				
			}
			.header-logo{
				float: left;
			    width: 62px;
			    margin-top: 22px
			}
			.logo {
    			position: relative;
    			
    			width: 56px;
    			height: 56px;
    			overflow: hidden;
			}
			.header-nav{
				width: 850px;
				height: 100px;
				float: left;
			}
			.nav-category {
			    position: relative;
			    float: left;
			    width: 127px;
			    height: 88px;
			    padding-right: 15px;
		
			}
			.nav-list {
				list-style-type: none;
			    position: relative;
			    z-index: 10;
			    float: left;
			    width: 1100px;
			    height: 88px;
			    margin: 0;
			    padding: 12px 0 0 30px;
			    font-size: 16px;
			    
			}
			.nav-item{
				display: flex;
				
				justify-content: space-around;
				
				
			}
			a.nav-item{
				padding: 26px 10px 38px;
			}
			a:link{
				color:#757575 ;
				text-decoration: none;
			}
			li {
			    float: left;    
			}
			.header-search {
				display: flex;
			    float: right;
				margin-top: 25px;
			}
			.input{
				font-size:1.4em;
				height:2em;
				border:1px solid #c8cccf;
				color:#6a6f77;
				padding: 0px;
 
			}

			.home-hero{
				width: 1263px;
				height: 670px;
			}
			
			
			
			
			
			
			
			
			
			
			
			
			
			
		.hero-top-left{
			display: flex;
			width: 240px;
			height: 460px;
			float: left;
			margin-top:0px ;
			background-color: #C8CCCF;
		}	
		.hero-top-right{
			width: 1000px;
			float:left;
		}	
		
		.home-cateage{
				display: flex;
			 	color:#757575 ;
			    height: 420px;
			    flex-direction: column;
	
		}
		li.nav-item{
			height: 42px;
			
		}
			
		
		
		
		
		
		
		
		.home-bottem{
			
			width: 1263px;
			height: 170px;
			margin-top: 14px ;

		
		}
		
		
		
		.bottem-span{
			float: left;
			margin-left:14px ;
			width: 226px;
			height: 170px;
			background: #5f5750;
		}
		
		

		li.bottem-left-li{
			list-style-type: none;
		}
		
		.bottem-left li {
	
		    position: relative;
		    float: left;
		    width: 47px;
		    height: 70px;
		    padding: 0 3px;
		    padding-top: 18px;
		    
		}
		.bottem-span16{
			float: left;
			margin-left: 14px;
			width: 1006px;
			height: 170px;
			background: #ccc;
		}
		.bottem-right img{
			margin-left: 14px;
			width:316px ;
			height: 170px;
		}	
		</style>
	</head>
	<body>
		
		<div class="site-topbar">
			<div class="site-topbar-nav">
				<a href="" class="toper-cateage">小米官网</a>
				|
				<a href="" class="toper-cateage">小米官网</a>
				|
				<a href="" class="toper-cateage">小米官网</a>
				|
				<a href="" class="toper-cateage">小米官网</a>
				|
				<a href="" class="toper-cateage">小米官网</a>
				|
				<a href="" class="toper-cateage">小米官网</a>
				|
				<a href="" class="toper-cateage">小米官网</a>
				|
				<a href="" class="toper-cateage">小米官网</a>
				
			</div>
			
		</div>
		
		<div class="site-header">
			
			<div class="container">
				<div class="header-logo" >
					<a href="#" class="logo">
						<img src="imag/logo-mi2.png" / width="56px" height="56px">
					</a> 
				</div>
				<div class="header-nav">
					<ul class="nav-list">

						<li class="nav-category"></li>
						<li data-index="0" ><a href="#" class="nav-item">Xiaomi手机</a></li>
						<li data-index="1" ><a href="#" class="nav-item">Redmi手机</a></li>
						<li data-index="2" ><a href="#" class="nav-item">电视</a></li>
						<li data-index="3" ><a href="#" class="nav-item">笔记本</a></li>
						<li data-index="4" ><a href="#" class="nav-item">平板</a></li>
						<li data-index="5" ><a href="#" class="nav-item">家电</a></li>
						<li data-index="6" ><a href="#" class="nav-item">路由器</a></li>
						<li data-index="7" ><a href="#" class="nav-item">服务中心</a></li>
						<li data-index="8" ><a href="#" class="nav-item">社区</a></li>
					</ul>
				</div>
				
				<div class="header-search">
					<form>
						<input type="text"  class="input"/>
						
					  	<span class="iconfont icon-sousuo" ></span>
					</form>
				
				</div>
				
			</div>
		</div>
		
		<div class="home-hero">

			<div class="hero-top" style="width: 1240px; height:460px ;">
				<div class="hero-top-left" >
					<ul class="home-cateage">
						<li data-index="0" class="nav-item"><span class="text">笔记本  平板</span></li>
						<li data-index="1" class="nav-item"><span class="text">笔记本  平板</span></li>
						<li data-index="2" class="nav-item"><span class="text">笔记本  平板</span></li>
						<li data-index="3" class="nav-item"><span class="text">笔记本  平板</span></li>
						<li data-index="4" class="nav-item"><span class="text">笔记本  平板</span></li>
						<li data-index="5" class="nav-item"><span class="text">笔记本  平板</span></li>
						<li data-index="6" class="nav-item"><span class="text">笔记本  平板</span></li>
						<li data-index="7" class="nav-item"><span class="text">笔记本  平板</span></li>
						<li data-index="8" class="nav-item"><span class="text">笔记本  平板</span></li>
						<li data-index="9" class="nav-item"><span class="text">笔记本  平板</span></li>
					</ul>
				</div>
				<div class="hero-top-right">
					<img src="imag/daa8668ce81bc05a5b8a6ef05072047d.jpg" / width="1020px " height="460px">
					
				</div>
			</div>
			
			<div class="home-bottem">
				<div class="bottem-span">
					<ul class="bottem-left">
						<li class="bottem-left-li">小米秒杀</li>
						<li class="bottem-left-li">小米秒杀</li>
						<li class="bottem-left-li">小米秒杀</li>
						<li class="bottem-left-li">小米秒杀</li>
						<li class="bottem-left-li">小米秒杀</li>
						<li class="bottem-left-li">小米秒杀</li>
					</ul>
				</div>
				<div class="bottem-span16">
					<div class="bottem-right">
						<img src="https://i1.mifile.cn/a4/xmad_15645846942857_zGfhK.jpg" />
						<img src="https://i1.mifile.cn/a4/xmad_15645846942857_zGfhK.jpg" />
						<img src="https://i1.mifile.cn/a4/xmad_15645846942857_zGfhK.jpg" />
					</div>
				</div>
				
			</div>
		</div>
	</body>
</html>

                                                                       效果图

  • 7
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值