第九十一节,html5+css3pc端固定布局,完成首页
html5+css3pc端固定布局,完成首页
此时我们的首页就完成了
首页效果
其他页面我就不做了,原理相同,做其他页面时将头尾css分离调用即可
大纲算法
我们看看大纲算法比较清晰,说明符合规则
html代码
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>瓢城旅行社</title>
<link rel="stylesheet" href="css/index.css">
</head>
<body> <!--导航-->
<header class="dao-hang">
<div class="dao-hang2">
<h1 class="log">瓢城旅行社</h1>
<nav>
<h2>网站导航</h2>
<ul>
<li class="dao-hang-lie-biao"><h3><a href="index.html">首页</a></h3></li>
<li class="dao-hang-lie-biao"><h3><a href="#">旅游资讯</a></h3></li>
<li class="dao-hang-lie-biao"><h3><a href="#">机票订购</a></h3></li>
<li class="dao-hang-lie-biao"><h3><a href="#">风景欣赏</a></h3></li>
<li class="dao-hang-lie-biao"><h3><a href="#">公司简介</a></h3></li>
</ul>
</nav>
</div>
</header> <!--搜索区域-->
<div class="sou-suo">
<h2>站内搜索</h2>
<div class="sou-suo2"></div>
<div class="sou-suo3">
<input type="text" placeholder="请输入搜索内容">
<button>搜索</button>
</div>
</div> <!--主体-->
<section class="zhu-ti">
<div class="zhu-ti2">
<h2>热门旅游</h2>
<p>国内旅游、国外旅游、自助旅游、自驾旅游、油轮签证、主题旅游等各种最新热门旅游推荐</p>
</div>
<div class="tu">
<img src="img/tour1.jpg">
<h3>曼谷-芭提雅6日游曼谷-芭提雅6日游曼谷-芭提雅6日游曼谷-芭提雅6日游曼谷-芭提雅6日游曼谷-芭提雅6日游曼谷-芭提雅6日游</h3>
<div class="jia-ge">
<span>¥<strong>2864</strong>起</span>
<em>满意度70%</em>
</div>
<div class="shu-xing">
<span>自助旅游</span>
</div>
</div>
<div class="tu">
<img src="img/tour2.jpg">
<h3>马尔代夫双鱼岛Olhuveli4晚6日自助游上海出发,机+酒 包含:早晚餐+快艇 </h3>
<div class="jia-ge">
<span>¥<strong>2864</strong>起</span>
<em>满意度20%</em>
</div>
<div class="shu-xing">
<span>自助旅游</span>
</div>
</div>
<div class="tu">
<img src="img/tour3.jpg">
<h3>海南双飞5日游含盐城接送,全程挂牌四星酒店,一价全含,零自费“自费项目”免费送</h3>
<div class="jia-ge">
<span>¥<strong>2864</strong>起</span>
<em>满意度69%</em>
</div>
<div class="shu-xing">
<span>自助旅游</span>
</div>
</div>
<div class="tu">
<img src="img/tour4.jpg">
<h3>富山-大阪-东京8日游暑期亲子,2天自由,无导游安排自费项目,全程不强迫购物 </h3>
<div class="jia-ge">
<span>¥<strong>2864</strong>起</span>
<em>满意度36%</em>
</div>
<div class="shu-xing">
<span>自助旅游</span>
</div>
</div>
<div class="tu">
<img src="img/tour5.jpg">
<h3>法瑞意德12日游4至5星,金色列车,少女峰,部分THE MALL </h3>
<div class="jia-ge">
<span>¥<strong>2864</strong>起</span>
<em>满意度12%</em>
</div>
<div class="shu-xing">
<span>自助旅游</span>
</div>
</div>
<div class="tu">
<img src="img/tour6.jpg">
<h3>巴厘岛6日半自助游蓝梦出海,独栋别墅,悦榕庄下午茶,纯玩 </h3>
<div class="jia-ge">
<span>¥<strong>2864</strong>起</span>
<em>满意度10%</em>
</div>
<div class="shu-xing">
<span>自助旅游</span>
</div>
</div>
<div class="tu">
<img src="img/tour7.jpg">
<h3>塞舌尔迪拜9日自助游一游两国,4晚塞舌尔,2晚迪拜,香港EK往返 </h3>
<div class="jia-ge">
<span>¥<strong>2864</strong>起</span>
<em>满意度5%</em>
</div>
<div class="shu-xing">
<span>自助旅游</span>
</div>
</div>
<div class="tu">
<img src="img/tour8.jpg">
<h3>花样姐姐土耳其9日或10日游最高立减3000!中餐六菜一汤+土耳其当地美食满足您挑剔味蕾 </h3>
<div class="jia-ge">
<span>¥<strong>2864</strong>起</span>
<em>满意度46%</em>
</div>
<div class="shu-xing">
<span>自助旅游</span>
</div>
</div>
<div class="tu">
<img src="img/tour9.jpg">
<h3>大阪-京都-箱根双飞6日游盐城直飞,不走回头路,境外无自费,超值之旅 </h3>
<div class="jia-ge">
<span>¥<strong>2864</strong>起</span>
<em>满意度19%</em>
</div>
<div class="shu-xing">
<span>自助旅游</span>
</div>
</div>
</section> <!--尾部-->
<footer class="wei-bu">
<div class="wei-bu2">
<div class="yy dd1">
<h2>合作伙伴</h2>
<hr>
<ul>
<li>途牛旅游网</li>
<li>驴妈妈旅游网</li>
<li>携程旅游</li>
<li>中国青年旅行社</li>
</ul>
</div>
<div class="yy dd1">
<h2>旅游FAQ</h2>
<hr>
<ul>
<li>旅游合同签订方式?</li>
<li>儿童价是基于什么制定的?</li>
<li>旅游的线路品质怎么界定的?</li>
<li>单房差是什么?</li>
<li>旅游保险有那些种类?</li>
</ul>
</div>
<div class="yy dd1">
<h2>联系方式</h2>
<hr>
<ul>
<li>微博:weibo.com/ycku</li>
<li>邮件:ycku@ycku.com</li>
<li>地址:江苏盐城无名路123号</li>
</ul>
</div>
</div>
<div class="ban-quan">
<p>Copyright © YCKU 瓢城旅行社 | 苏ICP备120110119号 | 旅行社经营许可证:L-YC-BK12345</p>
</div>
</footer>
</body>
</html>
css代码
@charset "utf-8";
/*通用样式*/
*{
margin:;
padding:;
}
ul{
list-style-type: none;
}
a{
text-decoration: none;
}
/*通用样式结束*/ /*导航区域*/
.dao-hang{
width: 100%;
min-width:1263px;
height: 70px;
background-color: #333;
color: azure;
}
.dao-hang .dao-hang2{
width: 1263px;
height: 70px;
margin: 0 auto;
}
.dao-hang .dao-hang2 .log{
width: 240px;
height: 70px;
float: left;
background-image: url("../img/logo.png");
text-indent:-9999px;
}
.dao-hang .dao-hang2 h2{
display: none;
}
.dao-hang .dao-hang2 ul{
float: right;
}
.dao-hang .dao-hang2 .dao-hang-lie-biao{
width: 120px;
height: 70px;
float: left;
text-align: center;
line-height: 70px;
}
.dao-hang .dao-hang2 .dao-hang-lie-biao a{
display: block;
width: 120px;
height: 70px;
color: azure;
}
.dao-hang .dao-hang2 .dao-hang-lie-biao a:hover{
background-color: #ff4d51;
}
/*导航区域结束*/ /*搜索区域*/
.sou-suo{
width: 100%;
min-width:1263px;
height: 600px;
background: url("../img/search.jpg") no-repeat center;
position: relative;
}
.sou-suo h2{
display: none;
}
.sou-suo .sou-suo2{
width: 600px;
height: 60px;
background-color: #000000;
position: absolute;
top: 50%;
left: 50%;
margin-left: -300px;
margin-top: -30px;
border-radius: 8px;
opacity: 0.7;
}
.sou-suo .sou-suo3{
width: 600px;
height: 60px;
position: absolute;
top: 50%;
left: 50%;
margin-left: -300px;
margin-top: -30px;
border-radius: 8px;
}
.sou-suo .sou-suo3 input{
width: 500px;
height: 50px;
border: none;
border-radius: 8px;
margin: 5px 0 5px 5px;
padding: 0 5px 0 5px;
font-size: 22px;
line-height: 50px;
}
.sou-suo .sou-suo3 button{
width: 70px;
height: 50px;
border: none;
border-radius: 8px;
float: right;
margin: 5px 8px 5px 0;
font-size: 22px;
line-height: 50px;
cursor: pointer;
}
.sou-suo .sou-suo3 button:hover{
background-color: #C6C6C6;
} /*主体区*/
.zhu-ti{
width: 1263px;
height: 1150px;
margin: 0 auto;
}
.zhu-ti .zhu-ti2{
text-align: center;
padding: 10px 0 10px 0;
}
.zhu-ti .zhu-ti2 h2{
margin: 10px 0 10px 0;
font-size: 45px;
color: #666666;
}
.zhu-ti .zhu-ti2 p{
margin: 10px 0 10px 0;
color: #666666;
}
.zhu-ti .tu{
display: inline-block;
vertical-align: bottom;
padding: 5px 5px 5px 5px;
border: 1px solid #DDDDDD;
border-radius: 6px;
position: relative;
margin: 14px 0 10px 15px;
}
.zhu-ti .tu img{
vertical-align: middle;
}
.zhu-ti .tu h3{
width: 380px;
height: 32px;
font-size: 14px;
font-weight: normal;
line-height: 32px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.zhu-ti .tu .jia-ge{
width: 380px;
height: 40px;
line-height: 40px;
}
.zhu-ti .tu .jia-ge span{
font-size: 14px;
color: #FF6600;
}
.zhu-ti .tu .jia-ge span strong{
font-size: 20px;
margin: 0 5px 0 5px;
}
.zhu-ti .tu .jia-ge em{
font-style: normal;
float: right;
font-size: 14px;
color: #999999;
}
.zhu-ti .tu .shu-xing{
background-color: #59B200;
width: 92px;
height: 26px;
line-height: 26px;
text-align: center;
border-radius: 0 0 6px 0;
position: absolute;
top: 5px;
left: 5px;
color: #fff6fc;
}
/*尾部*/
.wei-bu{
min-width:1263px;
height: 360px;
background-color: #222222;
margin: 20px 0 0 0;
}
.wei-bu .wei-bu2{
width: 1263px;
height: 280px;
/*background-color: #5dff59;*/
margin: 0 auto;
}
.wei-bu .wei-bu2 .yy{
width: 385px;
height: 280px;
/*background-color: #1232ff;*/
display: inline-block;
margin: 0 0 0 20px;
vertical-align: top;
overflow: hidden;
}
.wei-bu .wei-bu2 .yy h2{
/*background-color: #ffe627;*/
color: #CCCCCC;
padding: 20px 0 0 20px;
}
.wei-bu .wei-bu2 .yy hr{
padding: 3px 0 3px 0;
border: none;
border-bottom: 1px dashed #333;
}
.wei-bu .wei-bu2 .yy ul{
height: 200px;
/*background-color: #ff4450;*/
padding: 5px 5px 8px 20px;
overflow: hidden;
}
.wei-bu .wei-bu2 .yy ul li{
font-size: 20px;
line-height:;
color: #666666;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.wei-bu .ban-quan{
height: 79px;
background-color: #000000;
margin: 0 auto;
line-height: 79px;
text-align: center;
color: #fffdfd;
}
第九十一节,html5+css3pc端固定布局,完成首页的更多相关文章
- 第八十七节,html5+css3pc端固定布局,大纲算法,section和div,结构分析
html5+css3pc端固定布局,大纲算法,section和div,结构分析 一.大纲算法 在HTML5中有一个很重要的概念,叫做HTML5 大纲算法(HTML5Outliner),它的用途是为用户 ...
- 第九十节,html5+css3pc端固定布局,底部区域,说明区域,版权区域
html5+css3pc端固定布局,底部区域,说明区域,版权区域 完成: HTML代码: <!--尾部--> <footer class="wei-bu"> ...
- 第八十九节,html5+css3pc端固定布局,热门旅游取,标题介绍区,旅游项目区
html5+css3pc端固定布局,热门旅游取,标题介绍区,旅游项目区 样式: html代码: <!--主体--> <section class="zhu-ti" ...
- 第八十六节,html5+css3pc端固定布局,网站结构,CSS选择器,完成导航
html5+css3pc端固定布局,网站结构,CSS选择器,完成导航 页面采用1280的最低宽度设计,去掉滚动条为1263像素. 项目是PC端的固定布局,会采用像素(px)单位. 网站结构语义 在没有 ...
- 第八十八节,html5+css3pc端固定布局,搜索区,插入大图,搜索框
html5+css3pc端固定布局,搜索区,插入大图,搜索框 设置一个div作为搜索区域 1.宽度为百分之百 2.最小宽度为1263,因为要考虑到手机,等小屏幕缩小后宽度会自适应,导致破坏布局,将最小 ...
- 第 31 章 项目实战-PC 端固定布局[5]
学习要点: 1.底部区域 2.说明区域 3.版权及证件区 主讲教师:李炎恢 本章主要开始使用学习用 HTML5 和 CSS3 来构建 Web 页面,第一个项目采用 PC 端固定布局来实现. 一.底部区 ...
- 第 31 章 项目实战-PC 端固定布局[4]
学习要点: 1.热门旅游区 2.标题介绍区 3.旅游项目区 主讲教师:李炎恢 本章主要开始使用学习用 HTML5 和 CSS3 来构建 Web 页面,第一个项目采用 PC 端固定布局来实现. 一.热门 ...
- 第 31 章 项目实战-PC 端固定布局[3]
学习要点: 1.搜索区 2.插入大图 3.搜索框 主讲教师:李炎恢 本章主要开始使用学习用 HTML5 和 CSS3 来构建 Web 页面,第一个项目采用 PC 端固定布局来实现. 一.搜索区 本节课 ...
- 第 31 章 项目实战-PC端固定布局[2]
学习要点: 1.大纲算法 2.section和div 3.结构分析 主讲教师:李炎恢 本章主要开始使用学习用HTML5和CSS3来构建Web页面,第一个项目采用PC端 固定布局来实现. 一.大纲算法 ...
随机推荐
- python爬虫-知乎登录
#!/usr/bin/env python3 # -*- coding: utf-8 -*- ''' Required - requests (必须) - pillow (可选) ''' import ...
- JS 处理十六进制颜色渐变算法-输入颜色,输出渐变rgb数组
html颜色有几种表示方式: 英文单词颜色值:background-color:Blue:十六进制颜色值:background-color:#FFFFFF: RGB颜色值三元数字:backgroun ...
- PHP绿色集成环境在云服务器上的应用,PHPWAMP在服务器上搭建网站案例
问:什么叫WAMP?答:Windows下的Apache+Mysql+PHP,称之为WAMP. 本文案例采用的PHP集成环境是我自己开发的纯绿色版WAMP软件(PHPWAMP). 我在这款集成环境里集成 ...
- CodeForces 645C Enduring Exodus
枚举,三分. 首先,这$n+1$个人一定是连续的放在一起的.可以枚举每一个起点$L$,然后就是在$[L,R]$中找到一个位置$p$,使得$p4最优,因为越往两边靠,距离就越大,在中间某位置取到最优解, ...
- codeforces 192A Funky Numbers
time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standa ...
- 明天opp¥this xuexi 资料在高中一班
明天opp¥this xuexi 资料在高中一班
- 采用rest接口对接而非webservice
代码示例 public static String queryForCTI(String url){ String targetURL = getCTIurl()+"/"+url; ...
- JSONP 的工作原理是什么?
利用<script>标签没有跨域限制的"漏洞"来达到与第三方通讯的目的. 当需要通讯时,本站脚本创建一个<script>元素,地址指向第三方的API网址,形 ...
- c# 读取ACCESS 数据库
using System; using System.Collections.Generic; using System.Data.OleDb; using System.IO; using Syst ...
- 安装 zabbix 时遇到的一个问题
安装 zabbix 2.0.3,到最后阶段,遇到一个问题: PHP bcmath extension missing, php configuration parameter --enable-bc ...