html5 头和底部导航固定
2017-01-19 11:50
204 查看
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style>
.content {
}
.nav {
width:100%;
height:30px;
margin:0 auto;
background:#f00;
position:fixed;
bottom:0;
text-align:center;
}
.navtop {
width:100%;
height:30px;
margin:0 auto;
background:#f00;
position:fixed;
top:0;
text-align:center;
}
</style>
</head>
<body>
<div class="navtop">头导航</div>
<div class="content">
收快递费建设大街法律手段<br/>
收快递费建设大街法律手段<br/>
收快递费建设大街法律手段<br/>
<canvas id="myCanvas" width="200" height="100"></canvas>
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" height="190">
<polygon points="100,10 40,180 190,60 10,60 160,180"
style="fill:red;stroke:blue;stroke-width:3;fill-rule:evenodd;" />
</svg>
<svg width="500" height="190">
<circle cx="100" cy="50" r="40" stroke="black" stroke-width="2" fill="red" />
<circle cx="300" cy="50" r="40" stroke="black" stroke-width="2" fill="blue" />
</svg>
</div>
<div class="nav">导航</div>
<script type="text/javascript">
var c=document.getElementById("myCanvas");
var cxt=c.getContext("2d");
cxt.fillStyle="#FF0000";
cxt.fillRect(0,0,150,75);
cxt.moveTo(10,10);
cxt.lineTo(150,50);
cxt.lineTo(10,50);
cxt.stroke();
</script>
</body>
</html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style>
.content {
}
.nav {
width:100%;
height:30px;
margin:0 auto;
background:#f00;
position:fixed;
bottom:0;
text-align:center;
}
.navtop {
width:100%;
height:30px;
margin:0 auto;
background:#f00;
position:fixed;
top:0;
text-align:center;
}
</style>
</head>
<body>
<div class="navtop">头导航</div>
<div class="content">
收快递费建设大街法律手段<br/>
收快递费建设大街法律手段<br/>
收快递费建设大街法律手段<br/>
<canvas id="myCanvas" width="200" height="100"></canvas>
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" height="190">
<polygon points="100,10 40,180 190,60 10,60 160,180"
style="fill:red;stroke:blue;stroke-width:3;fill-rule:evenodd;" />
</svg>
<svg width="500" height="190">
<circle cx="100" cy="50" r="40" stroke="black" stroke-width="2" fill="red" />
<circle cx="300" cy="50" r="40" stroke="black" stroke-width="2" fill="blue" />
</svg>
</div>
<div class="nav">导航</div>
<script type="text/javascript">
var c=document.getElementById("myCanvas");
var cxt=c.getContext("2d");
cxt.fillStyle="#FF0000";
cxt.fillRect(0,0,150,75);
cxt.moveTo(10,10);
cxt.lineTo(150,50);
cxt.lineTo(10,50);
cxt.stroke();
</script>
</body>
</html>
相关文章推荐
- 仿天涯底部固定漂浮导航
- bootstrap 固定底部导航自适应
- 仿天涯底部固定漂浮导航
- LinearLayout 布局 底部固定导航
- HTML5 固定底部的footer功能栏
- 纯CSS打造兼容各大浏览器的底部固定悬浮导航
- HTML5 固定底部的footer功能栏
- HTML5,指定内容滚动到底部固定
- 总结--IE6,IE7,IE8,火狐都支持:js/css 底部固定, 底部固定漂浮导航效果
- 固定底部导航菜单-续集(BottomMenu-移动端V3.0)
- 第九十节,html5+css3pc端固定布局,底部区域,说明区域,版权区域
- 纯css实现固定在网页底部菜单导航
- 仿天涯底部固定漂浮导航
- bootstrap 固定底部导航自适应
- 固定底部导航
- 仿天涯底部固定漂浮导航
- 纯CSS实现底部固定漂浮导航
- <转>js 底部固定, 底部固定漂浮导航,无JS纯CSS定义
- Android界面,固定顶部、底部导航。中间可滑动
- jquerymobile header导航和footer底部固定