
批改狀態(tài):合格
老師批語:現(xiàn)在看到這些頁面,是不是有思路了, 不怕了
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>蘇寧易購(suning.com)</title>
<link rel="stylesheet" href="css/css Pre format.css" />
<link rel="stylesheet" href="css/index.css" />
<link rel="stylesheet" href="icon-font/iconfont.css" />
<link rel="stylesheet" href="css/header.css" />
<link rel="stylesheet" href="css/main.css" />
<link rel="stylesheet" href="css/footer.css" />
</head>
<body>
<header>
<div class="ss">
<a href=""><img src="images/ss/fl.png" alt="" class="ss_1" /></a>
<a href=""><img src="images/ss/161734725987957105.gif" alt="" class="ss_2" /></a>
<a href=""><img src="images/ss/dl.png" alt="" class="ss_3" /></a>
</div>
</header>
<main>
<!-- 搜索 -->
<div class="magnifier">
<div>
<p class="iconfont icon-search"></p>
<input type="text" value="家電生活,踏青春游記" />
</div>
</div>
<!-- banner圖 -->
<div class="banner">
<img src="images/ss/7859b5310cdf431497a9b9fee0110d8a.png" alt="" />
</div>
<!-- 秒殺區(qū) -->
<div class="ms">
<ul>
<li>
<a href=""> <img src="images/ms/ms_1.png " alt="" /> </a>
<a href="">蘇寧秒殺</a>
</li>
<li>
<a href=""> <img src="images/ms/ms_2.png " alt="" /> </a>
<a href="">蘇寧超市</a>
</li>
<li>
<a href=""> <img src="images/ms/ms_3.png " alt="" /> </a>
<a href="">蘇寧拼購</a>
</li>
<li>
<a href=""> <img src="images/ms/ms_4.png " alt="" /> </a>
<a href="">手機(jī)數(shù)碼</a>
</li>
<li>
<a href=""> <img src="images/ms/ms_5.png " alt="" /> </a>
<a href="">蘇寧家電</a>
</li>
<li>
<a href=""> <img src="images/ms/ms_6.png " alt="" /> </a>
<a href="">免費(fèi)水果</a>
</li>
<li>
<a href=""> <img src="images/ms/ms_7.png " alt="" /> </a>
<a href="">super會員</a>
</li>
<li>
<a href=""> <img src="images/ms/ms_8.png " alt="" /> </a>
<a href="">簽到有禮</a>
</li>
<li>
<a href=""> <img src="images/ms/ms_9.png" alt="" /> </a>
<a href="">領(lǐng)券中心</a>
</li>
<li>
<a href=""> <img src="images/ms/ms_10.png" alt="" /> </a>
<a href="">更多頻道</a>
</li>
</ul>
</div>
<!-- 大禮包 -->
<div class="dlb">
<a href="" class="dlb_1"><img src="images/dlb/dlb_1.png" alt="" /> </a>
<a href="" class="dlb_2"><img src="images/dlb/dlb_2.gif" alt="" /></a>
<a href="" class="dlb_3"><img src="images/dlb/dlb_3.gif" alt="" /></a>
</div>
<div class="xh">
<div class="cnxh"><img src="images/xh/cnxh.webp" alt="" /></div>
<div>
<ul>
<li>
<img src="images/xh/xh_01.webp" alt="" />
<p>小米米家掃地機(jī)器人智能家用全自動掃拖一體機(jī)激光...</p>
<div>
<img src="images/xh/zy.png" alt="" />
<span>大聚惠</span>
</div>
<div>
<span>1499</span>
<span>1900+評價</span>
</div>
</li>
<li>
<img src="images/xh/xh_02.webp" alt="" />
<p>蘇寧級物益生菌酵素櫻花漱口水500ml 清新口氣除口...</p>
<div>
<img src="images/xh/zy.png" alt="" />
<span>大聚惠</span>
</div>
<div>
<span>¥15.8</span>
<span>1900+評價</span>
</div>
</li>
<li>
<img src="images/xh/xh_03.webp" alt="" />
<p>富林(FOLEE)制氧機(jī)(器械) SFK-3 便攜式氧氣....帶魚 段海鮮水產(chǎn)</p>
<div>
<img src="images/xh/zy.png" alt="" />
<span>大聚惠</span>
</div>
<div>
<span>¥14.9</span>
<span>1900+評價</span>
</div>
</li>
<li>
<img src="images/xh/xh_04.webp" alt="" />
<p>鮮美來東海帶魚600g新鮮帶魚段海鮮水產(chǎn)</p>
<div>
<img src="images/xh/zy.png" alt="" />
<span>大聚惠</span>
</div>
<div>
<span>¥15.9</span>
<span>1900+評價</span>
</div>
</li>
<li>
<img src="images/xh/xh_05.webp" alt="" />
<p>海信65英寸65A52F懸浮全面屏全金屬機(jī)身電視</p>
<div>
<img src="images/xh/zy.png" alt="" />
<span>大聚惠</span>
</div>
<div>
<span>¥3699</span>
<span>1900+評價</span>
</div>
</li>
<li>
<img src="images/xh/xh_06.webp" alt="" />
<p>Ferrero費(fèi)列羅意大利進(jìn)口費(fèi)列羅榛果金莎巧克力T3...</p>
<div>
<img src="images/xh/zy.png" alt="" />
<span>大聚惠</span>
</div>
<div>
<span>¥21.9</span>
<span>1900+評價</span>
</div>
</li>
</ul>
</div>
</div>
<div class="snlogo">
<img src="images/xh/snlogo.png" alt="" />
</div>
<div class="bg"></div>
</main>
<footer>
<div>
<div class="iconfont icon-home"></div>
<!-- <a href="">首頁</a> -->
<p>首頁</p>
</div>
<div>
<div class="iconfont icon-layers"></div>
<!-- <a href="">分類</a> -->
<p>分類</p>
</div>
<div>
<div class="iconfont icon-kehuguanli"></div>
<!-- <a href="">驚喜</a> -->
<p>排行榜</p>
</div>
<div>
<div class="iconfont icon-shopping-cart"></div>
<!-- <a href="">購物車</a> -->
<p>購物車</p>
</div>
<div>
<div class="iconfont icon-user"></div>
<!-- <a href="">未登錄</a> -->
<p>我的易購</p>
</div>
</footer>
</body>
</html>
/* css預(yù)格式化 */
* {
padding: 0;
margin: 0;
box-sizing: border-box;
}
html {
font-size: 10px;
font-family: Microsoft YaHei;
}
body {
font-size: 1.6rem;
/* width: 100vw;
height: 100vh; */
}
/* 去掉標(biāo)簽前面的小點 */
li {
list-style: none;
}
/* 去掉a鏈接的下劃線 */
/* 給a鏈接一個灰色(默認(rèn)藍(lán)色太難看) */
a {
text-decoration: none;
color: #7b7b7b;
}
/* 媒體查詢,根據(jù)屏幕的寬度不同,從而選擇不同的樣式規(guī)則 */
/* 當(dāng)html到480px的時候 字體變?yōu)?2px */
@media screen and (min-width: 480px) {
html {
font-size: 12px;
}
}
/* 當(dāng)html到640px的時候 字體變?yōu)?4px */
@media screen and (min-width: 640px) {
html {
font-size: 14px;
}
}
/* 當(dāng)html到720px的時候 字體變?yōu)?6px */
@media screen and (min-width: 720px) {
html {
font-size: 16px;
}
}
footer {
display: flex;
/* 設(shè)置分散對齊 */
/* justify-content: center; */
}
/* flex支持嵌套布局 */
/* flex的項目可以又是一個flex容器 */
footer > div {
display: flex;
/* 水平居中 */
justify-content: center;
/* 垂直居中 */
align-items: center;
/* 設(shè)置排列方式 */
flex-flow: column nowrap;
}
/* 給icon圖標(biāo)設(shè)置大小 */
footer div .iconfont {
font-size: 2rem;
}
/* 設(shè)置字體大小 */
footer div p {
font-size: 1rem;
}
footer div div {
margin: 0 3rem;
}
header .ss {
display: flex;
align-items: center;
padding: 0 2rem;
}
.ss a .ss_1,
.ss a .ss_3 {
margin: 0.5rem 0;
width: 2.5rem;
}
.ss a .ss_1 {
margin-right: 5rem;
}
.ss a .ss_2 {
width: 23rem;
margin-right: 5rem;
}
/* 頭部 */
header {
background-color: #ffdb47;
position: fixed;
top: 0;
left: 0;
right: 0;
height: 6.5vh;
}
/* 主體 */
main {
/* background-color: #f7f7f7; */
background-color: #f7f7f7;
position: absolute;
top: 6.5vh;
left: 0;
right: 0;
bottom: 8vh;
min-height: 85.5vh;
}
/* 頁尾 */
footer {
height: 8vh;
border-top: #ccc 1px solid;
position: fixed;
bottom: 0;
left: 0;
right: 0;
}
-main.css
main .magnifier {
display: flex;
background-color: #ffdb47;
justify-content: center;
z-index: 100;
padding: 1rem 0;
}
main .magnifier div {
background-color: #fff;
width: 95vw;
border-radius: 2rem;
display: flex;
padding: 0.8rem 1rem;
align-items: center;
}
.magnifier div p {
font-size: 1.9rem;
color: #ccc;
padding-right: 0.5rem;
}
.magnifier div input {
border: none;
font-size: 1.7rem;
color: #666;
}
.banner {
display: flex;
justify-content: center;
background: linear-gradient(#ffdb47, #f7f7f7 12rem);
}
.banner img {
height: 14rem;
border-radius: 1rem;
}
.ms ul {
display: flex;
flex-flow: row wrap;
justify-content: space-evenly;
padding: 1rem;
}
.ms ul li {
flex: 1 1 20%;
display: flex;
flex-flow: column nowrap;
justify-content: center;
align-items: center;
}
.ms ul li a {
font-size: 1.2rem;
}
.ms ul li a img {
height: 5rem;
width: 5rem;
}
.dlb {
display: flex;
padding: 2rem 0;
}
.dlb a {
margin: 0 0.1rem;
}
.dlb .dlb_1 img {
width: 50vw;
height: 18vh;
}
.dlb .dlb_2 img,
.dlb .dlb_3 img {
width: 25vw;
height: 18vh;
}
.xh {
background-color: #f7f7f7;
}
.xh .cnxh {
display: flex;
justify-content: center;
align-items: center;
}
.xh .cnxh img {
width: 50rem;
}
.xh div ul {
display: flex;
flex-flow: row wrap;
justify-content: center;
/* align-items: center; */
}
.xh div ul li {
margin: 0.5rem;
display: flex;
flex-flow: column wrap;
background-color: #ffffff;
width: 45vw;
}
.xh div ul li img {
border-radius: 1rem;
width: 45vw;
}
.xh div ul li P {
font-size: 1.5rem;
padding: 0.5rem;
}
.xh div ul li div {
display: flex;
align-items: center;
flex-flow: row nowrap;
margin-bottom: 1rem;
}
.xh div ul li div:first-of-type img {
margin: 0rem 0.5rem;
width: 3rem;
height: 1.5rem;
}
.xh div ul li div:first-of-type span {
font-size: 1rem;
padding: 0 0.5rem;
border: solid 1px #000;
border-radius: 0.5rem;
}
.xh div ul li div:last-of-type {
position: absolute;
}
.xh div ul li div:last-of-type span:first-of-type {
font-weight: bolder;
font-size: 1.7rem;
color: red;
padding: 0 0.5rem;
}
.xh div ul li div:last-of-type span:last-of-type {
font-size: 1rem;
color: #999;
}
.snlogo img {
width: 100%;
}
.bg {
height: 8vh;
}
微信掃碼
關(guān)注PHP中文網(wǎng)服務(wù)號
QQ掃碼
加入技術(shù)交流群
Copyright 2014-2025 http://ipnx.cn/ All Rights Reserved | php.cn | 湘ICP備2023035733號