您好,登錄后才能下訂單哦!
這篇文章主要介紹如何使用div+css實現網站首頁,文中介紹的非常詳細,具有一定的參考價值,感興趣的小伙伴們一定要看完!
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>叮咚網首頁</title>
<!--
<link href="叮咚網首頁.css" rel="stylesheet" type="text/css"/>
-->
<style type="text/css">
.main{
width:100%;
height:2010px;
border:1px solid #000;
text-decoration: none;
}
.top{
width:100%;
height:52px;
border:1px solid #000;
}
.downMenu{
width:100%;
height:30px;
font:normal normal 20px "宋體";
color:#fff;
background-color: #000000;
}
#search{
margin-left:520px;
}
a{
text-decoration: none;
}
#img1{
margin-left:330px;
}
#logo{
font:normal normal 20px "宋體";
padding-bottom: 5px;
}
#d{
padding-bottom:30px;
margin-left:290px;
}
a:link{
font-size: 20px;
color:aquamarine;
}
a:visited{
color:darkgray;
}
a:hover{
color:#FFFFFF;
}
a:active{
color:cadetblue;
}
.c{
margin-left:10px;
}
#img7{
width: 100%;
}
.commodity{
font:normal bold 40px "新宋體";
}
.bottom{
text-align: center;
}
#img5{
width:100%;
height:80px;
}
.img2{
float:left;
}
.img3{
float:left;
margin-left:40px;
padding-right: 30px;
}
.hi1{
float:left;
margin-left:50px;
padding-top:60px;
text-align:center;
}
.hi2{
float:left;
margin-left:50px;
padding-top:20px;
text-align:center;
}
</style>
</head> <body> <div class="main"> <div class="top"> <div id="logo"> <img src="img/logo.gif" title="叮咚網logo" alt="logo"></img> <img src="img/header.png" title="img1" alt="img1" id="img1"></img> <a href="登錄.html" target="_blank" id="d"><font color="darkcyan">登錄</font></a> <a href="注冊.html" target="_blank"><font color="darkcyan">注冊</font></a> <a href="購物車.html" target="_blank"><font color="darkcyan">購物車</font></a> </div> </div> <div class="downMenu"> <a href="#" target="_blank">首頁</a> <a href="#" target="_blank">手機數碼</a> <a href="#" target="_blank">電腦辦公</a> <a href="#" target="_blank">學習用品</a> <a href="#" target="_blank">家具電器</a> <input id="search" type="text" name="search" value="search"> <input type="submit" name="submit" value="submit"> </div> <div class="slideshow"> <img src="img/1.jpg" width="1333px" height="600px"> </div> <div class="commodity"> 熱門商品<img src="img/title2.jpg" class="c"> </div> <div class="hotImg"> <img src="img/big01.jpg" class="img2"> <img src="img/middle01.jpg" class="img3"> <div class="hi1"> <img src="img/small08.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">電飯煲</font><br /> <font face="黑體" color="red" size="3px" align="center">¥299.00</font> </div> <div class="hi1"> <img src="img/small05.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">飲水機</font><br /> <font face="黑體" color="red" size="3px" align="center">¥439.00</font> </div> <div class="hi1"> <img src="img/small04.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">烤箱</font><br /> <font face="黑體" color="red" size="3px" align="center">¥389.00</font> </div> <div class="hi2"> <img src="img/small08.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">電飯煲</font><br /> <font face="黑體" color="red" size="3px" align="center">¥299.00</font> </div> <div class="hi2"> <img src="img/small05.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">飲水機</font><br /> <font face="黑體" color="red" size="3px" align="center">¥439.00</font> </div> <div class="hi2"> <img src="img/small04.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">烤箱</font><br /> <font face="黑體" color="red" size="3px" align="center">¥389.00</font> </div> <div class="hi2"> <img src="img/small08.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">電飯煲</font><br /> <font face="黑體" color="red" size="3px" align="center">¥299.00</font> </div> <div class="hi2"> <img src="img/small05.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">飲水機</font><br /> <font face="黑體" color="red" size="3px" align="center">¥439.00</font> </div> <div class="hi2"> <img src="img/small04.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">烤箱</font><br /> <font face="黑體" color="red" size="3px" align="center">¥389.00</font> </div> <img src="img/ad.jpg" id="img7"/> </div> <div class="commodity"> 最新商品<img src="img/title2.jpg" class="c"> </div> <div class="newImg"> <img src="img/big01.jpg" class="img2"> <img src="img/middle01.jpg" class="img3"> <div class="hi1"> <img src="img/small08.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">電飯煲</font><br /> <font face="黑體" color="red" size="3px" align="center">¥299.00</font> </div> <div class="hi1"> <img src="img/small05.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">飲水機</font><br /> <font face="黑體" color="red" size="3px" align="center">¥439.00</font> </div> <div class="hi1"> <img src="img/small04.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">烤箱</font><br /> <font face="黑體" color="red" size="3px" align="center">¥389.00</font> </div> <div class="hi2"> <img src="img/small08.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">電飯煲</font><br /> <font face="黑體" color="red" size="3px" align="center">¥299.00</font> </div> <div class="hi2"> <img src="img/small05.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">飲水機</font><br /> <font face="黑體" color="red" size="3px" align="center">¥439.00</font> </div> <div class="hi2"> <img src="img/small04.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">烤箱</font><br /> <font face="黑體" color="red" size="3px" align="center">¥389.00</font> </div> <div class="hi2"> <img src="img/small08.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">電飯煲</font><br /> <font face="黑體" color="red" size="3px" align="center">¥299.00</font> </div> <div class="hi2"> <img src="img/small05.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">飲水機</font><br /> <font face="黑體" color="red" size="3px" align="center">¥439.00</font> </div> <div class="hi2"> <img src="img/small04.jpg"><br /> <font face="黑體" color="#000000" size="3px" align="center">烤箱</font><br /> <font face="黑體" color="red" size="3px" align="center">¥389.00</font> </div> </div> <div class="img5"> <img src="img/footer.jpg" id="img5"> </div> <div class="bottom"> <a href="#" target="_blank"><font color="dodgerblue" size="3px"> 關于我們</font></a> <a href="#" target="_blank"><font color="dodgerblue" size="3px">聯系我們</font></a> <a href="#" target="_blank"><font color="dodgerblue" size="3px">招賢納士</font></a> <a href="#" target="_blank"><font color="dodgerblue" size="3px">法律聲明</font></a> <a href="#" target="_blank"><font color="dodgerblue" size="3px">友情鏈接</font></a> <a href="#" target="_blank"><font color="dodgerblue" size="3px">支付方式</font></a> <a href="#" target="_blank"><font color="dodgerblue" size="3px">配送方式</font></a> <a href="#" target="_blank"><font color="dodgerblue" size="3px">服務聲明</font></a> <a href="#" target="_blank"><font color="dodgerblue" size="3px">廣告聲明</font></a> </div> <div class="bottom"> <font size="2px">Copyright©2015-2016西部開源 版權所有</font> </div> </div> </body>
</html>
以上是“如何使用div+css實現網站首頁”這篇文章的所有內容,感謝各位的閱讀!希望分享的內容對大家有幫助,更多相關知識,歡迎關注億速云行業資訊頻道!
免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。