码迷,mamicode.com
首页 > Web开发 > 详细

【css】修正ie6下不支持position:fixed

时间:2014-08-01 19:31:02      阅读:202      评论:0      收藏:0      [点我收藏+]

标签:style   blog   http   color   os   io   ar   html   

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
    <meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
    <title>Document</title>
</head>
<body>
<style>
.fixed_bar{position: fixed;
top: 0;
_position: absolute;
_top: expression(eval(document.documentElement.scrollTop));
left: 0;
background-color:red;
height:30px;
width:100%;
}
p{height:2000px;}
* html,* html body /* 修正IE6振动bug */{background-image:url(about:blank);background-attachment:fixed;}
</style>

 <div class=‘fixed_bar‘>
    我是固定 头部
 </div>
<p>主题内容</p>
</body>
</html>

 

【css】修正ie6下不支持position:fixed,布布扣,bubuko.com

【css】修正ie6下不支持position:fixed

标签:style   blog   http   color   os   io   ar   html   

原文地址:http://www.cnblogs.com/positive/p/3885492.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!