__x__(30)0908第五天__导航条的练习 <div>版本
效果图:
html源代码:
<!doctype html>
<html>
<head>
<meta charset="utf-8" />
<title>湖南城市学院</title> <link rel="stylesheet" type="text/css" href="css/hncu.css" />
</head> <body>
<div id="hncu_header"> </div> <div id="hncu_nav">
<div>
<a href="#">首页</a>
</div> <div>
<a href="#">新闻</a>
</div> <div>
<a href="#">联系</a>
</div> <div>
<a href="#">关于</a>
</div>
</div> <div id="hncu_content">
<div id="hncu_left"></div>
<div id="hncu_center"></div>
<div id="hncu_right"></div>
</div> <div id="hncu_footer"> </div>
</body>
</html>
CSS源代码:
@charset "utf-8"; *{
margin: 0px;
padding: 0px;
} body{
background-color: #bfc;
} #hncu_header{
width: 1000px;
height: 200px;
background-color: skyblue; margin:10px auto 10px;
} #hncu_nav{
width: 1000px;
height: 70px;
background-color: blue; margin:0px auto 10px; overflow:hidden;
zoom:;
} #hncu_nav a{
width: 25%;
color:white; float:left;
line-height:70px;
text-align:center;
text-decoration: none;
} #hncu_nav a:link{
background-color: blue;
} #hncu_nav a:visited{
background-color: blue;
} #hncu_nav a:hover{
background-color: red;
} #hncu_nav a:active{
color: blue;
} #hncu_content{
width: 1000px;
height: 600px;
background-color: yellow; margin:0px auto 10px;
} #hncu_left{
width: 200px;
height: 500px;
background-color: green; margin-top:50px;
float:left;
} #hncu_center{
width: 580px;
height: 500px;
background-color: #bfc; margin-top:50px;
margin-right: 10px;
margin-left: 10px;
float:left;
} #hncu_right{
width: 200px;
height: 500px;
background-color: pink; margin-top:50px;
float:left;
} #hncu_footer{
width:1000px;
height:200px;
background-color:skyblue; margin:0px auto 10px;
}
__x__(30)0908第五天__导航条的练习 <div>版本的更多相关文章
- __x__(31)0908第五天__导航条的练习 <ul> 版本
效果图: html代码: <!doctype html> <html> <head> <meta charset="utf-8" /&g ...
- __x__(29)0908第五天__高度塌陷 问题
高度塌陷 在文档流中,父元素的高度默认是被子元素撑开的. 但是当为 子元素 设置 float 时,子元素会完全脱离文档流,无法再撑开父元素,导致父元素高度塌陷...以致于布局混乱 变成 BFC块级格式 ...
- __x__(34)0908第五天__ 定位 position
position 定位 指将原始摆放到页面的任意位置. 继承性:no 默认值:static 没有定位,原始出现在正常的文档流中 可选值: static : 默认值,元素没有开启定位 ...
- __x__(35)0908第五天__ 层级 z-index
如果三个 div 全部设置 position: absolute; 绝对定位,且未设置 z-index, 则从代码结构上 下面的元素 会盖住 上面的元素. z-index 层级: 通过 z-i ...
- __x__(36)0908第五天__背景 background
1. 背景 background: red url(img/cat.gif) repeat-x fixed; 2. 背景颜色 background-color: red; 3. 背景图片 backgr ...
- __x__(40)0909第五天__表格 table 的 css 样式 美化
如果就向下面的代码那样,不写 tbody , 则浏览器自添加 tbody , 并将所有的 tr 移入 tbody 意味着 tr 并非 table 的子元素,而是 tbody 的子元素. 所以 以后编写 ...
- __x__(41)0909第五天__长表格
长表格 银行流水,表格很长... 则需要将表格分为 表头 thead ,主体数据 tbody , 表格底部 tfoot 三个标签无顺序要求,易于维护:thead → tfoot → tbody 如果没 ...
- __x__(32)0908第五天__Photoshop的基本操作
1. 设置 Photoshop 的单位为 像素px 2. 标尺 显示与隐藏 Ctrl + r 3. 放大与缩小 Ctrl + 1 放大到100% Ctrl + 0 适应屏幕 Alt + ...
- __x__(35)0908第五天__opacity 透明度
opacity 透明度 设置一个 0 - 1 之间的值. opacity: 0; 完全透明 opacity: 0.5 半透明 opacity: 1; 完全不透明 缺点: IE8及以 ...
随机推荐
- SSH HTTP代理
SSH 连接 参照https://stackoverflow.com/questions/19161960/connect-with-ssh-through-a-proxy 若要使用goflyway连 ...
- oracle数据库驱动(ojdbc)
第1部分 Q:为什么oralce的jdbc驱动,在maven上搜索到把pom配置复制到pom.xml里进行引用的时候会报错? ANS:虽然能在maven仓库里搜索到,但貌似不能用,原因是oracle是 ...
- @JsonView的使用,entity中指定向前台返回哪些字段
使用步骤: 1.使用接口来声明多个视图 2.在值对象的get方法上指定视图 3.在Controller方法上指定视图
- luogu 4345 Lucas的变形应用
求 sigma i由0-k C(n,i) 利用Lucas定理+整除分块将C(n/p,i/p)利用i/p分块,得到k/p-1个整块(p-1)和一个小块(k%p) 最后得到式子 F(n,k)=F(n/p, ...
- shell 批量获取ip 和主机名
[DNyunwei@YZSJHL24-209 li]$ cat jia.sh #!/bin/bash ip=`cat jia.ip` for i in $ip;do HostName=`ssh -t ...
- jQuery实现获取选中复选框的值
<!DOCTYPE html><html><head> <meta charset="UTF-8"> <title>Jq ...
- 通过命令修改mysql的提示符
在cmd窗口操作mysql数据库的时候,前面的提示符永远都是mysql>,这个提示符可以通过命令修改. 在登录mysql时修改: mysql -uroot -p --prompt 提示符 登录后 ...
- windows环境隐藏命令行窗口运行Flask项目
Linux下可以使用nohub来使Flask项目在后台运行,而windows环境下没有nohub命令,如何让Flask项目在windows中在后台运行而不显示命令行窗口呢? 1.写一个.bat脚本来启 ...
- 「luogu3258」[JLOI2014] 松鼠的新家
https://www.luogu.org/problemnew/show/P3258 (树剖裸题 树上差分 = = 差分 + lca 1. 树上差分基本思想:和差分一样,用前缀和的思想来处理解(操作 ...
- sea.js 个人入门
玉伯 : http://seajs.org/docs/ 说这两个JS 必须提到AMD.commonjs两种不同的规范: 奇舞团:http://www.75team.com/archives/882 知 ...