(前端开发)网页制作案例

HTML(index.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>A宝</title>
	<link rel="stylesheet" href="./css/base.css">
	<link rel="stylesheet" href="./css/index.css">
</head>
<body>
	<!-- 头部区域 -->
	<div class="header">
		<div class="wrapper">
			<div class="logo">
				<a href="https://www.baidu.com/">学成在线</a>
			</div>
			<div class="nav">
				<ul>
					<li><a href="#" class="active">首页</a></li>
					<li><a href="#">课程</a></li>
					<li><a href="#">职业规划</a></li>
				</ul>
			</div>
			<div class="search">
				<input type="text" placeholder="请输入关键词" >
				<a href="#"></a>
			</div>
			<div class="user">
				<a href="#">
					<img src="./uploads/user.png" alt="">
					<span>A宝</span>
				</a>
			</div>
		</div>
	</div>

	<!-- banner区域 -->
	<div class="banner">
		<div class="wrapper">
			<div class="left">
				<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="#">UI设计</a></li>
					<li><a href="#">产品</a></li>
				</ul>
			</div>

			<div class="right">
				<h3>我的课程表</h3>
				<div class="content">
					<dl>
						<dt>数据可视化课程</dt>
						<dd><span>正在学习</span>-<strong>echarts使用步骤</strong></dd>
					</dl>
					<dl>
						<dt>Vue3医疗项目课程  </dt>
						<dd><span>正在学习</span>-<strong>认识组合式API</strong></dd>
					</dl>
					<dl>
						<dt>React核心技术课程</dt>
						<dd><span>正在学习</span>-<strong>rudex配合TS使用</strong></dd>
					</dl>
					<a href="#">全部课程</a>
				</div>
			</div>
		</div>
	</div>

	<!-- recommend区域 -->
	<div class="recommend">
		<div class="wrapper">
			<h3>精品推荐</h3>
			<ul>
				<li><a href="#">HTML</a></li>
				<li><a href="#">CSS</a></li>
				<li><a href="#">JavaScript</a></li>
				<li><a href="#">Node.js</a></li>
				<li><a href="#">Ajax</a></li>
				<li><a href="#">Vue2.0</a></li>
				<li><a href="#">Vue3.0</a></li>
				<li><a href="#">TypeScript</a></li>
				<li><a href="#">React</a></li>
			</ul>
			<a href="#" class="modify">修改兴趣</a>
		</div>
	</div>

	<!-- 精品推荐 -->
	<div class="course wrapper">
		<div class="hd">
			<h3>精品推荐</h3>
			<a href="#" class="more">查看全部</a>
		</div>
		<div class="bd">
			<ul>
				<li>
				  	<a href="#">
						<div class="pic"><img src="./uploads/course01.png" alt=""></div>
						<div class="text">
						  	<h4>JavaScript数据看板项目实战</h4>
							<p><span>高级</span> · <i>1125</i>人在学习</p>
						</div>
				 	 </a>
				</li>

				<li>
					<a href="#">
						<div class="pic"><img src="./uploads/course02.png" alt=""></div>
						<div class="text">
							<h4>Vue.js实战——面经全端项目</h4>
							<p><span>高级</span> · <i>2726</i>人在学习</p>
						</div>
					</a>
				</li>

				<li>
					<a href="#">
						<div class="pic"><img src="./uploads/course03.png" alt=""></div>
						<div class="text">
							<h4>玩转Vue全家桶,iHRM人力资源项目</h4>
							<p><span>高级</span> · <i>9456</i>人在学习</p>
						</div>
					</a>
				</li>

				<li>
					<a href="#">
						<div class="pic"><img src="./uploads/course04.png" alt=""></div>
						<div class="text">
							<h4>Vue.js实战医疗项目——优医问诊</h4>
							<p><span>高级</span> · <i>7192</i>人在学习</p>
						</div>
					</a>
				</li>

				<li>
					<a href="#">
						<div class="pic"><img src="./uploads/course05.png" alt=""></div>
						<div class="text">
							<h4>小程序实战:小兔鲜电商小程序项目</h4>
							<p><span>高级</span> · <i>2703</i>人在学习</p>
						</div>
					</a>
				</li>

				<li>
					<a href="#">
						<div class="pic"><img src="./uploads/course06.png" alt=""></div>
						<div class="text">
							<h4>前端框架Flutter开发实战</h4>
							<p><span>高级</span> · <i>2841</i>人在学习</p>
						</div>
					</a>
				</li>

				<li>
					<a href="#">
						<div class="pic"><img src="./uploads/course07.png" alt=""></div>
						<div class="text">
							<h4>熟练使用React.js——极客园H5项目</h4>
							<p><span>高级</span> · <i>95682</i>人在学习</p>
						</div>
					</a>
				</li>

				<li>
					<a href="#">
						<div class="pic"><img src="./uploads/course08.png" alt=""></div>
						<div class="text">
							<h4>熟练使用React.js——极客园PC端项目</h4>
							<p><span>高级</span> · <i>904</i>人在学习</p>
						</div>
					</a>
				</li>

				<li>
					<a href="#">
						<div class="pic"><img src="./uploads/course09.png" alt=""></div>
						<div class="text">
							<h4>前端实用技术,Fetch API 实战</h4>
							<p><span>高级</span> · <i>1516</i>人在学习</p>
						</div>
					</a>
				</li>

				<li>
					<a href="#">
						<div class="pic"><img src="./uploads/course10.png" alt=""></div>
						<div class="text">
							<h4>前端高级Node.js零基础入门教程</h4>
							<p><span>高级</span> · <i>2766</i>人在学习</p>
						</div>
					</a>
				</li>
			  </ul>
		</div>
	</div>

	<!-- 前端 -->
	<div class="wrapper">
		<div class="hd">
			<h3>前端开发工程师</h3>
			<ul>
				<li><a href="#" class="active">热门</a></li>
				<li><a href="#">初级</a></li>
				<li><a href="#">中极</a></li>
				<li><a href="#">高级</a></li>
			</ul>
			<a href="#" class="more">查看全部</a>
		</div>
		<div class="bd">
			<div class="left">
				<img src="./uploads/web_left.png" alt="">
			</div>
			<div class="right">
				<img src="./uploads/web_top.png" alt="">
				<ul>
					<li>
						<a href="">
							<div class="pic"><img src="./uploads/web01.png" alt=""></div>
							<div class="text">
								<h4>JS高级JavaScript进阶面向对象</h4>
								<p><span>高级</span> · <i>101937</i>人在学习</p>
							</div>
						</a>
					</li>

					<li>
						<a href="#">
							<div class="pic"><img src="./uploads/web02.png" alt=""></div>
							<div class="text">
								<h4>零基础玩转微信小程序</h4>
								<p><span>高级</span> · <i>133781</i>人在学习</p>
							</div>
						</a>
					</li>

					<li>
						<div class="pic"><img src="./uploads/web03.png" alt=""></div>
						<div class="text">
							<h4>JavaScript基础---语法解析+项目实战</h4>
							<p><span>高级</span> · <i>8972</i>人在学习</p>
						</div>
					</li>

					<li>
						<div class="pic"><img src="./uploads/web04.png" alt=""></div>
						<div class="text">
							<h4>前端框架Vue2+Vue3全套视频</h4>
							<p><span>高级</span> · <i>26022</i>人在学习</p>
						</div>
					</li>
				</ul>
			</div>
		</div>
	</div>

	<!-- 版权 -->
	<div class="footer">
		<div class="wrapper">
			<div class="left">
				<div class="pic"><img src="./images/logo.png" alt=""></div>
				<div class="text">
					<p>学成在线致力于普及中国最好的教育它与中国一流大学和机构合作提供在线课程。
						© 2017年XTCG Inc.保留所有权利。-沪ICP备15025210号</p>	
				</div>
				<a href="#" class="down">下载APP</a>
			</div>

			<div class="right">
				<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>
				</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>
				</dl>

				<dl>
					<dt>合作伙伴</dt>
					<dd><a href="#">合作机构</a></dd>
					<dd><a href="#">合作导师</a></dd>
				</dl>
			</div>
		</div>
	</div>
</body>
</html>

CSS(base.css)

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

li {
    list-style: none;
}

a {
    text-decoration: none;
    color: #333;
}


CSS(index.css)

.wrapper {
    margin: 0 auto;
    width: 1200px;
}

body {
    background-color: #f3f5f7;
}

.header {
    height: 100px;
    background-color: #fff;
}

.header .wrapper {
    padding-top: 29px;
    display: flex;
}

.logo a {
    display: block;
    width: 195px;
    height: 41px;
    background-image: url(../images/logo.png);
    font-size: 0;
}

.nav ul {
    padding-left: 102px;
    display: flex;
}

.nav ul li {
    margin-right: 24px;
}

.nav ul li a {
    display: block;
    padding: 6px 8px;
    line-height: 27px;
    font-size: 19px;
}

.nav li .active,
.nav li a:hover{
    border-bottom: 2px solid #00a4ff;
}


.search {
    display: flex;
    margin-left: 64px;
    padding-left: 19px;
    padding-right: 12px;
    width: 412px;
    height: 40px;
    background-color: #f0e2bb;
    border-radius: 20px;
}

.search input {
    flex: 1;
    border: 0;
    background-color: transparent;
    outline: none;
}

.search input::placeholder {
    font-size: 14px;
    color: rgb(150, 94, 229);
}

.search a {
    align-self: center;
    width: 16px;
    height: 16px;
    background-image: url(../images/search.png);
}

.user {
    margin-left: 32px;
    margin-top: 4px;
}

.user img {
    padding-right: 7px;
    vertical-align: middle;
}

.user a span {
    font-size: 16px;
    color: #666;
}







.banner {
    height: 420px;
    background-color: #0092cb;
}

.banner .wrapper {
    display: flex;
    justify-content: space-between;
    height: 420px;
    background-image: url(../uploads/banner.png);
}

.banner .left {
    padding: 3px 20px;
    width: 191px;
    height: 420px;
    background-color: rgba(0,0,0,0.42);
}

.banner .left a {
    display: block;
    height: 46px;
    background: url(../images/right.png) no-repeat right center;
    line-height: 46px;
    font-size: 16px;
    color: #fff;
}

.banner .left a:hover {
    background-image: url(../images/right-hover.png);
    color: #00a4ff;
}

.banner .right {
    margin-top: 60px;
    width: 218px;
    height: 305px;
    background-color: #209dd5;
    border-radius: 10px;
}

.banner .right h3 {
    font-size: 15px;
    height: 48px;
    padding-left: 14px;
    padding-top: 18px;
    color: #fff;
    font-weight: 400;
}

.banner .right .content {
    padding: 14px;
    width: 218px;
    height: 257px;
    background-color: #fff;
    border-radius: 10px;
}
/* 
.banner .right dt{
    font-size: 14px;
    line-height: 20px;
    padding-bottom: 8px;
    color: #333333;
}

.banner .right dd span{
    font-size: 12px;
    line-height: 16px;
    color: #00a4ff;

}

.banner .right dd strong {
    font-size: 12px;
    line-height: 16px;
    font-weight: 400;
    color: #7d7d7d;
}

.banner .right dd {
    border-bottom: 1px solid #e0e0e0;
} */





.banner .right dl {
    margin-bottom: 12px;
    border-bottom: 1px solid #e0e0e0;
}

.banner .right dt {
    margin-bottom: 8px;
    font-size: 14px;
    line-height: 20px;
    font-weight: 700;
}

.banner .right dd {
    margin-bottom: 8px;
    font-size: 12px;
    line-height: 16px;
}

.banner .right dd span {
    color: #00a4ff;
}

.banner .right dd strong {
    color: #7d7d7d;
    font-weight: 400;
}

.banner .right a {
    display: block;
    height: 32px;
    background-color: #00a4ff;
    border-radius: 15px;
  
    font-size: 14px;
    font-weight: 400;
    color: #fff;
    text-align: center;
    line-height: 32px;
}









.recommend .wrapper{
    display: flex;
    width: 1200px;
    height: 60px;
    background-color: #fff;
    margin-top: 11px;
    padding: 18px 20px;
    box-shadow: 0px 1px 2px 0px rgba(211, 211, 211, 0.5);
}

.recommend ul {
    display: flex;
}

.recommend h3 {
    font-size: 18px;
    line-height: 25px;
    font-weight: 400;
    color: #00a4ff;
    padding-right: 20px;
}

.recommend li {
    font-size: 18px;
    line-height: 25px;
    font-weight: 400;
    color: #333333;
    padding-right: 24px;
    padding-left: 24px;
    border-right: 1px solid #e0e0e0;
}

.recommend li:nth-child(1) {
    padding-left: 0;
}

.recommend li:nth-child(9) {
    padding-right: 93px;
    border-right: none;
}
.recommend .modify {
    font-size: 16px;
    line-height: 22px;
    padding-top: 1px;
    padding-bottom: 2px;
    color: #00a4ff;
}







.course {
    margin-top: 15px;
}

.hd {
    display: flex;
    justify-content: space-between;
    height: 60px;
    line-height: 60px;
}

.hd h3 {
    font-size: 21px;
    font-weight: 400;
}

.hd .more {
    padding-right: 20px;
    font-size: 14px;
    color: #999999;
    background: url(../images/more.png) no-repeat right center;
}

.bd ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
}

.bd li {
    margin-bottom: 14px;
    width: 228px;
    height: 271px;
    background-color: pink;
}

.bd .pic {
    height: 156px;
}

.bd .text {
    padding: 20px;
    height: 115px;
    background-color: #fff;
}

.bd .text h4 {
    margin-bottom: 14px;
    height: 40px;
    font-size: 14px;
    line-height: 20px;
    color: #333333;
    font-weight: 400;
}

.bd .text p {
    font-size: 14px;
    line-height: 20px;
    color: #999999;
}

.bd .text span {
    color: #fa6444;
}

.hd .text p i {
    font-style: normal;
}








.hd ul {
    display: flex;
}

.hd ul li {
    padding: 0 30px;
}

.hd ul li .active {
    color: #00a4ff;
}

.bd {
    display: flex;
}

.bd .left {
    margin-right: 15px;
    width: 228px;
    height: 386px;
}










.footer {
    margin-top: 60px;
    padding-top: 60px;
    height: 273px;
    background-color: #fff;
}

.footer .wrapper {
    display: flex;
    justify-content: space-between;
}

.footer .left {
    width: 440px;
    /* background-color: pink; */
}

.footer .left .pic {
    width: 195px;
    height: 41px;
    margin-bottom: 24px;
}

.footer .left .text {
    font-size: 12px;
    color: #666;
}

.footer .left .down {
    display: block;
    margin-top: 14px;
    width: 120px;
    height: 36px;
    border: 1px solid #00a4ff;

    font-size: 16px;
    color: #00a4ff;
    text-align: center;
    line-height: 36px;
}

.footer .right {
    display: flex;
}

.footer .right dl {
    margin-left: 130px;
}

.footer .right dt {
    font-size: 16px;
    line-height: 23px;
    color: #333333;
    font-weight: 400;
    margin-bottom: 12px;
}

.footer .right dd {
    line-height: 24px;
    font-size: 14px;
    color: #666666;
}

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

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

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值