最后更多分享:前端字节跳动真题解析
开源分享:【大厂前端面试题解析+核心总结学习笔记+真实项目实战+最新讲解视频】
base.css
/\* 把我们所有标签的内外边距清零 \*/
\* {
margin: 0;
padding: 0;
/\* css3盒子模型,算上padding和margin \*/
box-sizing: border-box;
}
/\* em和i斜体的文字不倾斜 \*/
em,
i {
font-style: normal
}
/\* 去掉前面小圆点 \*/
li {
list-style: none
}
img {
/\* border: 0;照顾低版本浏览器 如果图片外面包含了链接会有边框的问题 \*/
border: 0;
/\* 取消图片底侧有空白缝隙的问题 \*/
vertical-align: middle
}
/\* 当我们鼠标经过button时,鼠标变成小手 \*/
button {
cursor: pointer
}
/\* 修改颜色 取消下划线 \*/
a {
color: #666;
text-decoration: none
}
a:hover {
color: #c81623
}
button,
input {
/\* "\5B8B\4F53"就是宋体的意思(Unicode编码)这样浏览器兼容性比较好 \*/
font-family: Microsoft YaHei, Heiti SC, tahoma, arial, Hiragino Sans GB, "\5B8B\4F53", sans-serif;
/\* 默认有灰色边框需要手动去掉 \*/
border: 0;
outline: none;
}
body {
/\* css3抗锯齿形 让文字显示更加清晰 \*/
-webkit-font-smoothing: antialiased;
background-color: #fff;
font: 12px/1.5 Microsoft YaHei, Heiti SC, tahoma, arial, Hiragino Sans GB, "\5B8B\4F53", sans-serif;
color: #666
}
/\* 隐藏 \*/
.hide,
.none {
display: none
}
/\* 清除浮动 \*/
.clearfix:after {
visibility: hidden;
clear: both;
display: block;
content: ".";
height: 0
}
.clearfix {
*zoom: 1
}
common.css
/\* 声明字体图标 路径要更换 \*/
@font-face {
font-family: 'icomoon';
src: url('../fonts/icomoon.eot?tomleg');
src: url('../fonts/icomoon.eot?tomleg#iefix') format('embedded-opentype'),
url('../fonts/icomoon.ttf?tomleg') format('truetype'),
url('../fonts/icomoon.woff?tomleg') format('woff'),
url('../fonts/icomoon.svg?tomleg#icomoon') format('svg');
font-weight: normal;
font-style: normal;
font-display: block;
}
/\* 版心 \*/
.w {
width: 1200px;
margin: 0 auto;
}
.fl {
float: left;
}
.fr {
float: right;
}
.style\_red {
color: #c81623;
}
/\* 快捷导航模块 \*/
.shortcut {
height: 32px;
line-height: 32px;
background-color: #f1f1f1;
}
.shortcut ul li {
float: left;
}
/\* 选择所有偶数li \*/
.shortcut .fr li:nth-child(even) {
width: 1px;
height: 12px;
background-color: #666;
margin: 9px 15px 0;
}
.arrow\_icon::after {
content: '\e91e';
font-family: 'icomoon';
margin-left: 6px;
}
/\* header头部制作 \*/
.header {
position: relative;
height: 105px;
}
.logo {
position: absolute;
top: 25px;
width: 171px;
height: 61px;
}
.logo a {
display: block;
width: 171px;
height: 61px;
background: url(../images/logo.png) no-repeat;
font-size: 0;
}
.search {
position: absolute;
left: 348px;
top: 25px;
width: 538px;
height: 36px;
border: 2px solid #b1191a;
}
.search input {
float: left;
width: 454px;
height: 32px;
padding-left: 10px;
}
.search button {
float: left;
width: 80px;
height: 32px;
background-color: #c81623;
font-size: 16px;
color: #fff;
}
.hotwords {
position: absolute;
left: 348px;
top: 66px;
}
.hotwords a {
margin: 0 10px;
}
.shopcar {
position: absolute;
right: 63px;
top: 25px;
width: 140px;
height: 35px;
line-height: 35px;
text-align: center;
border: 1px solid #dfdfdf;
background-color: #f7f7f7;
}
.shopcar::before {
content: '\e93a';
font-family: 'icomoon';
margin-right: 5px;
color: #b1191a;
}
.shopcar::after {
content: '\e920';
font-family: 'icomoon';
margin-left: 10px;
}
.count {
position: absolute;
top: -5px;
left: 105px;
height: 14px;
line-height: 14px;
color: #fff;
background-color: #e60012;
padding: 0 5px;
border-radius: 7px 7px 7px 0;
}
/\* nav导航部分 \*/
.nav {
height: 47px;
border-bottom: 2px solid #b1191a;
}
.nav .dropdown {
float: left;
width: 210px;
height: 45px;
background-color: #b1191a;
}
.nav .navitems {
float: left;
}
.dropdown .dt {
width: 100%;
height: 100%;
color: #fff;
font-size: 16px;
line-height: 45px;
text-align: center;
}
.dropdown .dd {
/\* display: none; \*/
width: 210px;
height: 465px;
background-color: #c81623;
margin-top: 2px;
}
.dropdown .dd ul li {
position: relative;
height: 31px;
line-height: 31px;
margin-left: 2px;
}
.dropdown .dd ul li:hover {
background-color: #fff;
}
.dropdown .dd ul li::after {
position: absolute;
top: 1px;
right: 10px;
color: #fff;
content: '\e920';
font-family: 'icomoon';
font-size: 14px;
}
.dropdown .dd ul li:hover a {
color: #c81623;
}
.dropdown .dd ul li a {
font-size: 14px;
color: #fff;
padding-left: 10px;
}
.navitems ul li {
float: left;
}
.navitems ul li a{
display: block;
height: 45px;
line-height: 45px;
font-size: 16px;
padding: 0 25px;
}
/\* 底部模块 \*/
.footer {
height: 415px;
padding-top: 30px;
background-color: #f5f5f5;
}
.mod\_service {
height: 80px;
border-bottom: 1px solid #ccc;
}
.mod\_service ul li {
float: left;
width: 300px;
height: 50px;
padding-left: 35px;
}
.mod\_service ul li h5 {
float: left;
width: 50px;
height: 50px;
background: url(../images/icons.png) no-repeat -252px -2px;
margin-right: 8px;
}
.service\_text h4 {
font-size: 14px;
}
.service\_text p {
font-size: 12px;
}
.mod\_help {
height: 185px;
border-bottom: 1px solid #ccc;
padding-top: 20px;
padding-left: 50px;
}
.mod\_help dl {
width: 200px;
float: left;
}
.mod\_help dl:last-child {
width: 90px;
text-align: center;
}
.mod\_help dl dt {
font-size: 16px;
margin-bottom: 10px;
}
.mod\_copyright {
text-align: center;
padding-top: 20px;
}
.links {
margin-bottom: 15px;
}
.links a {
margin: 0 3px;
}
.copyrights {
line-height: 20px;
}
index.html
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>品优购商城-正品低价、品质保障、配送及时、轻松购物!</title>
<!-- 网站说明 -->
<meta name="description"
content="品优购商城-专业的综合网上购物商城,销售家电、数码通讯、电脑、家居百货、服装服饰、母婴、图书、食品等数万个品牌优质商品.便捷、诚信的服务,为您提供愉悦的网上购物体验!" />
<!-- 关键字 -->
<meta name="Keywords" content="网上购物,网上商城,手机,笔记本,电脑,MP3,CD,VCD,DV,相机,数码,配件,手表,存储卡,京东" />
<!-- 引入页面favicon图标(网上在线转成ico文件放到根目录下) -->
<link rel="shortcut icon" href="favicon.ico">
<!-- 引入初始化css文件 -->
<link rel="stylesheet" href="css/base.css">
<!-- 引入公共样式文件 -->
<link rel="stylesheet" href="css/common.css">
<!-- 引入index.css文件 -->
<link rel="stylesheet" href="css/index.css">
</head>
<body>
<!-- 快捷导航模块 start-->
<section class="shortcut">
<div class="w">
<div class="fl">
<ul>
<li>品优购欢迎您! </li>
<li>
<a href="#">请登录</a>
<a href="register.html" class="style\_red">免费注册</a>
</li>
</ul>
</div>
<div class="fr">
<ul>
<li>我的订单</li>
<li></li>
<li class="arrow\_icon">我的品优购</li>
<li></li>
<li>品优购会员</li>
<li></li>
<li>企业采购</li>
<li></li>
<li class="arrow\_icon">关注品优购</li>
<li></li>
<li class="arrow\_icon">客户服务</li>
<li></li>
<li class="arrow\_icon">网站导航</li>
</ul>
</div>
</div>
</section>
<!-- 快捷导航模块 end-->
<!-- header头部模块制作 start -->
<header class="header w">
<!-- logo模块 -->
<div class="logo">
<h1>
<a href="index.html" title="品优购商城">品优购商城</a>
</h1>
</div>
<!-- search模块 -->
<div class="search">
<input type="search" name="" id="" placeholder="语言开发">
<button>搜索</button>
</div>
<!-- hotwords模块 -->
<div class="hotwords">
<a href="#" class="style\_red">优惠购首发</a>
<a href="#">亿元优惠</a>
<a href="#">9.9元团购</a>
<a href="#">每满99减30</a>
<a href="#">办公用品</a>
<a href="#">电脑</a>
<a href="#">手机</a>
</div>
<!-- shopcar模块 -->
<div class="shopcar">我的购物车
<i class="count">8</i>
</div>
</header>
<!-- header头部模块制作 end -->
<!-- nav导航部分 start -->
<nav class="nav">
<div class="w">
<div class="dropdown">
<div class="dt">全部商品分类</div>
<div class="dd">
<ul>
<li><a href="#">家用电器</a></li>
<li><a href="list.html">手机</a>、<a href="#">数码</a>、<a href="#">通信</a></li>
<li><a href="#">电脑</a>、<a href="#">办公</a></li>
<li><a href="#">家居</a>、<a href="#">家具</a>、<a href="#">厨具</a></li>
<li><a href="#">男装</a>、<a href="#">女装</a>、<a href="#">内衣</a>、<a href="#">童装</a></li>
<li><a href="#">手机</a>、<a href="#">数码</a>、<a href="#">通信</a></li>
<li><a href="#">手机</a>、<a href="#">数码</a>、<a href="#">通信</a></li>
<li><a href="#">手机</a>、<a href="#">数码</a>、<a href="#">通信</a></li>
<li><a href="#">手机</a>、<a href="#">数码</a>、<a href="#">通信</a></li>
<li><a href="#">手机</a>、<a href="#">数码</a>、<a href="#">通信</a></li>
<li><a href="#">手机</a>、<a href="#">数码</a>、<a href="#">通信</a></li>
<li><a href="#">手机</a>、<a href="#">数码</a>、<a href="#">通信</a></li>
<li><a href="#">手机</a>、<a href="#">数码</a>、<a href="#">通信</a></li>
<li><a href="#">手机</a>、<a href="#">数码</a>、<a href="#">通信</a></li>
<li><a href="#">手机</a>、<a href="#">数码</a>、<a href="#">通信</a></li>
</ul>
</div>
</div>
<div class="navitems">
<ul>
<li><a href="#">服装城</a></li>
<li><a href="#">服装城</a></li>
<li><a href="#">服装城</a></li>
<li><a href="#">服装城</a></li>
<li><a href="#">服装城</a></li>
<li><a href="#">服装城</a></li>
<li><a href="#">服装城</a></li>
<li><a href="#">服装城</a></li>
<li><a href="#">服装城</a></li>
</ul>
</div>
</div>
</nav>
<!-- nav导航部分 end -->
<!-- 首页专有模块 -->
<!-- main模块 start -->
<div class="w">
<div class="main">
<div class="focus">
<ul>
<li>
<img src="upload/focus1.png" alt="">
</li>
</ul>
<!-- 左侧按钮 -->
<a href="#" class="prev"><</a>
<!-- 右侧按钮 -->
<a href="#" class="next">></a>
<!-- 底部小圆点 -->
<ul class="promo\_nav">
<li class="selected"></li>
<li></li>
<li></li>
<li></li>
<li></li>
</ul>
</div>
<div class="newsflash">
<div class="news">
<div class="news-hd">
<h5>品优购快报</h5>
<a href="#" class="more">更多</a>
</div>
<div class="news-bd">
<ul>
<li><a href="#"><strong>[重磅]</strong> 它来了它来了,带着财宝走来了</a></li>
<li><a href="#"><strong>[重磅]</strong> 它来了它来了,带着财宝走来了</a></li>
<li><a href="#"><strong>[重磅]</strong> 它来了它来了,带着财宝走来了</a></li>
<li><a href="#"><strong>[重磅]</strong> 它来了它来了,带着财宝走来了</a></li>
<li><a href="#"><strong>[重磅]</strong> 它来了它来了,带着财宝走来了,lailailalallalall</a></li>
</ul>
</div>
</div>
<div class="lifeservice">
<ul>
<li>
<i></i>
<p>话费</p>
</li>
<li>
<i></i>
<p>话费</p>
</li>
<li>
<i></i>
<p>话费</p>
</li>
<li>
<i></i>
<p>话费</p>
</li>
<li>
<i></i>
<p>话费</p>
</li>
<li>
<i></i>
<p>话费</p>
</li>
<li>
<i></i>
<p>话费</p>
</li>
<li>
<i></i>
<p>话费</p>
</li>
<li>
<i></i>
<p>话费</p>
</li>
<li>
<i></i>
<p>话费</p>
</li>
<li>
<i></i>
<p>话费</p>
</li>
<li>
<i></i>
<p>话费</p>
</li>
</ul>
</div>
<div class="bargin">
<img src="upload/bargin.png" alt="">
</div>
</div>
</div>
</div>
<!-- main模块 end -->
<!-- 推荐模块 start -->
<div class="w recom">
<div class="recom-hd">
<img src="images/recom.png" alt="">
</div>
<div class="recom-bd">
<ul>
<li><img src="upload/recom\_03.png" alt=""></li>
<li><img src="upload/recom\_03.png" alt=""></li>
<li><img src="upload/recom\_03.png" alt=""></li>
<li><img src="upload/recom\_03.png" alt=""></li>
</ul>
</div>
</div>
<!-- 推荐模块 end -->
<!-- 猜你喜欢模块 start -->
<div class="w">
<div class="fav-hd">
<h5>猜你喜欢</h5>
<p>换一批</p>
</div>
<div class="fav-bd">
<ul>
<li>
<a href="#">
<div><img src="upload/fav1.png" alt=""></div>
<p>阳光美包新款单肩包女<br>包时尚子母包四件套女</p>
<p class="price">¥116.00</p>
</a>
</li>
<li>
<a href="#">
<div><img src="upload/fav2.png" alt=""></div>
<p>阳光美包新款单肩包女<br>包时尚子母包四件套女</p>
<p class="price">¥116.00</p>
</a>
</li>
<li>
<a href="#">
<div><img src="upload/fav3.png" alt=""></div>
<p>阳光美包新款单肩包女<br>包时尚子母包四件套女</p>
<p class="price">¥116.00</p>
</a>
</li>
<li>
<a href="#">
<div><img src="upload/fav4.png" alt=""></div>
<p>阳光美包新款单肩包女<br>包时尚子母包四件套女</p>
<p class="price">¥116.00</p>
</a>
</li>
<li>
<a href="#">
<div><img src="upload/fav5.png" alt=""></div>
<p>阳光美包新款单肩包女<br>包时尚子母包四件套女</p>
<p class="price">¥116.00</p>
</a>
</li>
<li>
<a href="#">
<div><img src="upload/fav6.png" alt=""></div>
<p>阳光美包新款单肩包女<br>包时尚子母包四件套女</p>
<p class="price">¥116.00</p>
</a>
</li>
</ul>
</div>
</div>
<!-- 猜你喜欢模块 end -->
<!-- 楼层区域模块 start -->
<div class="floor">
<!-- 1楼家用电器楼层 -->
<div class="w jiadian">
<div class="box-hd">
<h3>家用电器</h3>
<div class="tab\_list">
<ul>
<li><a href="#" class="style\_red">热门</a>|</li>
<li><a href="#">大家电</a>|</li>
<li><a href="#">生活电器</a>|</li>
<li><a href="#">厨房电器</a>|</li>
<li><a href="#">生活电器</a>|</li>
<li><a href="#">个护健康</a>|</li>
<li><a href="#">应季电器</a>|</li>
<li><a href="#">空气/净水</a>|</li>
<li><a href="#">新奇特</a>|</li>
<li><a href="#">高端电器</a></li>
</ul>
</div>
</div>
<div class="box-bd">
<div class="tab\_content">
<div class="tab\_list\_item">
<div class="col\_210">
<ul>
<li><a href="#">节能补贴</a></li>
<li><a href="#">节能补贴</a></li>
<li><a href="#">节能补贴</a></li>
<li><a href="#">节能补贴</a></li>
<li><a href="#">节能补贴</a></li>
<li><a href="#">节能补贴</a></li>
</ul>
<a href="#"><img src="upload/floor-1-1.png" alt=""></a>
</div>
<div class="col\_329">
<a href="#"><img src="upload/floor-1-b01.png" alt=""></a>
</div>
<div class="col\_221">
<a href="#" class="bb"><img src="upload/floor-1-2.png" alt=""></a>
<a href="#"><img src="upload/floor-1-3.png" alt=""></a>
</div>
<div class="col\_221">
<a href="#"><img src="upload/floor-1-4.png" alt=""></a>
</div>
<div class="col\_219">
<a href="#" class="bb"><img src="upload/floor-1-5.png" alt=""></a>
<a href="#"><img src="upload/floor-1-6.png" alt=""></a>
</div>
</div>
</div>
</div>
</div>
<!-- 2楼手机楼层 -->
<div class="w shouji">
<div class="box-hd">
<h3>手机</h3>
<div class="tab\_list">
<ul>
<li><a href="#" class="style\_red">热门</a>|</li>
<li><a href="#">大家电</a>|</li>
<li><a href="#">生活电器</a>|</li>
<li><a href="#">厨房电器</a>|</li>
<li><a href="#">生活电器</a>|</li>
<li><a href="#">个护健康</a>|</li>
<li><a href="#">应季电器</a>|</li>
<li><a href="#">空气/净水</a>|</li>
<li><a href="#">新奇特</a>|</li>
<li><a href="#">高端电器</a></li>
</ul>
</div>
</div>
<div class="box-bd">
<div class="tab\_content">
<div class="tab\_list\_item">
<div class="col\_210">
<ul>
<li><a href="#">节能补贴</a></li>
<li><a href="#">节能补贴</a></li>
<li><a href="#">节能补贴</a></li>
<li><a href="#">节能补贴</a></li>
<li><a href="#">节能补贴</a></li>
<li><a href="#">节能补贴</a></li>
</ul>
<a href="#"><img src="upload/floor-1-1.png" alt=""></a>
</div>
<div class="col\_329">
<a href="#"><img src="upload/floor-1-b01.png" alt=""></a>
</div>
<div class="col\_221">
<a href="#" class="bb"><img src="upload/floor-1-2.png" alt=""></a>
<a href="#"><img src="upload/floor-1-3.png" alt=""></a>
</div>
<div class="col\_221">
<a href="#"><img src="upload/floor-1-4.png" alt=""></a>
</div>
<div class="col\_219">
<a href="#" class="bb"><img src="upload/floor-1-5.png" alt=""></a>
<a href="#"><img src="upload/floor-1-6.png" alt=""></a>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- 楼层区域模块 end -->
<!-- 底部模块 start-->
<footer class="footer">
<div class="w">
<div class="mod\_service">
<ul>
<li>
<h5></h5>
<div class="service\_text">
<h4>正品保障</h4>
<p>正品保障,提供发票</p>
</div>
</li>
<li>
<h5></h5>
<div class="service\_text">
<h4>正品保障</h4>
<p>正品保障,提供发票</p>
</div>
</li>
<li>
<h5></h5>
<div class="service\_text">
<h4>正品保障</h4>
<p>正品保障,提供发票</p>
</div>
</li>
<li>
<h5></h5>
<div class="service\_text">
<h4>正品保障</h4>
<p>正品保障,提供发票</p>
</div>
</li>
</ul>
</div>
<div class="mod\_help">
<dl>
<dt>服务指南</dt>
<dd><a href="#">购物流程</a></dd>
<dd><a href="#">会员介绍</a></dd>
<dd><a href="#">生活旅行/团购</a></dd>
<dd><a href="#">常见问题</a></dd>
<dd><a href="#">大家电</a></dd>
<dd><a href="#">联系客服</a></dd>
</dl>
<dl>
<dt>服务指南</dt>
<dd><a href="#">购物流程</a></dd>
<dd><a href="#">会员介绍</a></dd>
<dd><a href="#">生活旅行/团购</a></dd>
<dd><a href="#">常见问题</a></dd>
<dd><a href="#">大家电</a></dd>
<dd><a href="#">联系客服</a></dd>
</dl>
<dl>
<dt>服务指南</dt>
<dd><a href="#">购物流程</a></dd>
<dd><a href="#">会员介绍</a></dd>
<dd><a href="#">生活旅行/团购</a></dd>
<dd><a href="#">常见问题</a></dd>
<dd><a href="#">大家电</a></dd>
<dd><a href="#">联系客服</a></dd>
</dl>
<dl>
<dt>服务指南</dt>
<dd><a href="#">购物流程</a></dd>
<dd><a href="#">会员介绍</a></dd>
<dd><a href="#">生活旅行/团购</a></dd>
<dd><a href="#">常见问题</a></dd>
<dd><a href="#">大家电</a></dd>
<dd><a href="#">联系客服</a></dd>
</dl>
<dl>
<dt>服务指南</dt>
<dd><a href="#">购物流程</a></dd>
<dd><a href="#">会员介绍</a></dd>
<dd><a href="#">生活旅行/团购</a></dd>
<dd><a href="#">常见问题</a></dd>
<dd><a href="#">大家电</a></dd>
<dd><a href="#">联系客服</a></dd>
</dl>
<dl>
<dt>帮助中心</dt>
<dd>
<img src="images/wx\_cz.jpg" alt="">
品优购客户端
</dd>
</dl>
</div>
<div class="mod\_copyright">
<div class="links">
<a href="#">关于我们</a>|<a href="#">联系我们</a>|<a href="#">联系客服</a>|<a href="#">商家入驻</a>|<a
href="#">营销中心</a>|<a href="#">手机品优购</a>|<a href="#">友情链接</a>|<a href="#">销售联盟</a>|<a
href="#">品优购社区</a>|<a href="#">品优购公益</a>|<a href="#">English Site</a>|<a href="#">ontact U</a>C
</div>
<div class="copyright">
地址:广东省广州市海珠区昌盛里12345678号一楼 邮编:510240 传真:010-789956378 邮箱:23432468264@qq.com <br>
京ICP备9787687364号京公网安备27645356472
</div>
</div>
</div>
</footer>
<!-- 底部模块 end-->
</body>
</html>
index.css
.main {
width: 980px;
height: 455px;
margin-left: 220px;
margin-top: 10px;
}
.focus {
position: relative;
float: left;
width: 721px;
height: 455px;
}
.focus ul li img {
width: 721px;
height: 455px;
}
.prev,
.next {
position: absolute;
top: 50%;
width: 30px;
height: 30px;
background: rgba(0, 0, 0, .3);
line-height: 30px;
text-align: center;
color: #fff;
}
.prev {
left: 0;
border-top-right-radius: 15px;
border-bottom-right-radius: 15px;
}
.next {
right: 0;
border-top-left-radius: 15px;
border-bottom-left-radius: 15px;
}
.promo\_nav {
position: absolute;
left: 50%;
margin-left: -35px;
bottom: 15px;
width: 70px;
height: 13px;
background-color: rgba(255,255,255,.3);
border-radius: 7px;
}
.promo\_nav li {
float: left;
width: 8px;
height: 8px;
background-color: #fff;
border-radius: 50%;
margin: 3px;
}
.promo\_nav .selected {
background-color: #ff5000;
}
.newsflash {
float: right;
width: 250px;
height: 455px;
}
.news {
height: 165px;
border: 1px solid #e4e4e4;
}
.lifeservice {
overflow: hidden;
height: 209px;
border: 1px solid #e4e4e4;
border-top: 0;
}
.bargin {
margin-top: 5px;
}
.news-hd {
height: 33px;
line-height: 33px;
border-bottom: 1px dotted #e4e4e4;
padding: 0 15px;
}
.news-hd h5 {
float: left;
font-size: 14px;
}
.news-hd .more {
float: right;
}
.news-hd .more::after {
content: '\e920';
font-family: 'icomoon';
}
.news-bd {
padding: 5px 15px 0;
}
.news-bd li {
height: 24px;
line-height: 24px;
/\* 文字溢出用省略号显示 \*/
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.lifeservice ul {
width: 252px;
}
.lifeservice ul li {
float: left;
width: 63px;
height: 71px;
border-right: 1px solid #e4e4e4;
border-bottom: 1px solid #e4e4e4;
text-align: center;
}
.lifeservice ul li i {
display: inline-block;
width: 25px;
height: 25px;
background-color: pink;
margin-top: 12px;
background: url(../images/icons.png) no-repeat -16px -16px;
}
/\* 推荐模块 \*/
.recom {
height: 163px;
margin-top: 12px;
background-color: #ebebeb;
}
.recom-hd {
float: left;
height: 163px;
width: 205px;
text-align: center;
padding-top: 30px;
background-color: #5c5251;
}
.recom-bd {
float: left;
}
.recom-bd ul li {
float: left;
position: relative;
}
.recom-bd ul li img {
width: 243px;
height: 163px;
}
.recom-bd ul li:nth-child(-n+3)::after {
content: '';
position: absolute;
top: 10px;
right: 0;
width: 1px;
height: 145px;
background-color: #ddd;
}
/\* 猜你喜欢模块 \*/
.fav-hd {
height: 42px;
line-height: 42px;
margin-top: 18px;
}
.fav-hd h5 {
float: left;
font-size: 18px;
font-weight: 400;
}
.fav-hd p {
float: right;
}
.fav-hd p::after {
content: '\ea2e';
font-family: 'icomoon';
margin-left: 10px;
margin-right: 20px;
}
.fav-bd {
height: 234px;
border: 1px solid #ededed;
}
.fav-bd ul {
width: 1200px;
}
.fav-bd ul li {
position: relative;
float: left;
width: 200px;
height: 234px;
}
.fav-bd ul li:nth-child(-n+5)::after {
content: '';
position: absolute;
bottom: 10px;
right: 0;
width: 1px;
height: 63px;
background-color: #ededed;
}
.fav-bd ul li div {
width: 200px;
height: 162px;
display: table-cell;
text-align: center;
vertical-align: middle;
}
.fav-bd ul li p {
margin-left: 34px;
margin-top: 2px;
font-size: 12px;
}
.fav-bd ul li .price {
font-size: 18px;
color: #df3033;
}
/\* 家用电器模块 \*/
.floor .w {
margin-top: 30px;
}
.box-hd {
height: 30px;
border-bottom: 2px solid #c81623;
}
.box-hd h3 {
float: left;
font-size: 18px;
color: #c81623;
font-weight: 400;
}
.tab\_list {
float: right;
line-height: 30px;
}
.tab\_list ul li {
float: left;
}
.tab\_list ul li a {
padding: 0 15px;
}
.box-bd {
height: 361px;
}
.tab\_list\_item>div {
float: left;
height: 361px;
}
.col\_210 {
width: 210px;
background-color: #f9f9f9;
text-align: center;
}
.col\_210 ul {
margin-left: 2px;
}
.col\_210 ul li {
float: left;
width: 85px;
height: 34px;
border-bottom: 1px solid #ccc;
line-height: 33px;
text-align: center;
margin-left: 10px;
}
.col\_329 {
width: 329px;
}
.col\_221 {
width: 221px;
border-right: 1px solid #ccc;
}
.col\_219 {
width: 219px;
}
.bb {
/\* 一般情况下,a如果包含有宽度的盒子,a需要转换为块级元素 \*/
display: block;
border-bottom: 1px solid #ccc;
}
list.html
<!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>列表页-正品低价、品质保障、配送及时、轻松购物!</title>
<!-- 网站说明 -->
<meta name="description"
content="品优购商城-专业的综合网上购物商城,销售家电、数码通讯、电脑、家居百货、服装服饰、母婴、图书、食品等数万个品牌优质商品.便捷、诚信的服务,为您提供愉悦的网上购物体验!" />
<!-- 关键字 -->
<meta name="Keywords" content="网上购物,网上商城,手机,笔记本,电脑,MP3,CD,VCD,DV,相机,数码,配件,手表,存储卡,京东" />
<!-- 引入页面favicon图标(网上在线转成ico文件放到根目录下) -->
<link rel="shortcut icon" href="favicon.ico">
<!-- 引入初始化css文件 -->
<link rel="stylesheet" href="css/base.css">
<!-- 引入公共样式文件 -->
<link rel="stylesheet" href="css/common.css">
<!-- 引入list.css文件 -->
<link rel="stylesheet" href="css/list.css">
</head>
<body>
<!-- 快捷导航模块 start-->
<section class="shortcut">
<div class="w">
<div class="fl">
<ul>
<li>品优购欢迎您! </li>
<li>
<a href="#">请登录</a>
<a href="register.html" class="style\_red">免费注册</a>
</li>
</ul>
</div>
<div class="fr">
<ul>
<li>我的订单</li>
<li></li>
<li class="arrow\_icon">我的品优购</li>
<li></li>
<li>品优购会员</li>
<li></li>
<li>企业采购</li>
<li></li>
<li class="arrow\_icon">关注品优购</li>
<li></li>
<li class="arrow\_icon">客户服务</li>
<li></li>
<li class="arrow\_icon">网站导航</li>
</ul>
</div>
</div>
</section>
<!-- 快捷导航模块 end-->
<!-- header头部模块制作 start -->
<header class="header w">
<!-- logo模块 -->
<div class="logo">
<h1>
<a href="index.html" title="品优购商城">品优购商城</a>
</h1>
</div>
<!-- 列表页新增的秒杀图标 -->
### 最后
好了,这就是整理的前端从入门到放弃的学习笔记,还有很多没有整理到,我也算是边学边去整理,后续还会慢慢完善,这些相信够你学一阵子了。
做程序员,做前端工程师,真的是一个学习就会有回报的职业,不看出身高低,不看学历强弱,只要你的技术达到应有的水准,就能够得到对应的回报。
**[开源分享:【大厂前端面试题解析+核心总结学习笔记+真实项目实战+最新讲解视频】](https://bbs.csdn.net/forums/4304bb5a486d4c3ab8389e65ecb71ac0)**
学习从来没有一蹴而就,都是持之以恒的,正所谓活到老学到老,真正懂得学习的人,才不会被这个时代的洪流所淘汰。
<div class="fr">
<ul>
<li>我的订单</li>
<li></li>
<li class="arrow\_icon">我的品优购</li>
<li></li>
<li>品优购会员</li>
<li></li>
<li>企业采购</li>
<li></li>
<li class="arrow\_icon">关注品优购</li>
<li></li>
<li class="arrow\_icon">客户服务</li>
<li></li>
<li class="arrow\_icon">网站导航</li>
</ul>
</div>
</div>
</section>
<!-- 快捷导航模块 end-->
<!-- header头部模块制作 start -->
<header class="header w">
<!-- logo模块 -->
<div class="logo">
<h1>
<a href="index.html" title="品优购商城">品优购商城</a>
</h1>
</div>
<!-- 列表页新增的秒杀图标 -->
### 最后
好了,这就是整理的前端从入门到放弃的学习笔记,还有很多没有整理到,我也算是边学边去整理,后续还会慢慢完善,这些相信够你学一阵子了。
做程序员,做前端工程师,真的是一个学习就会有回报的职业,不看出身高低,不看学历强弱,只要你的技术达到应有的水准,就能够得到对应的回报。
**[开源分享:【大厂前端面试题解析+核心总结学习笔记+真实项目实战+最新讲解视频】](https://bbs.csdn.net/forums/4304bb5a486d4c3ab8389e65ecb71ac0)**
学习从来没有一蹴而就,都是持之以恒的,正所谓活到老学到老,真正懂得学习的人,才不会被这个时代的洪流所淘汰。