css解決ie6 不支持 position:fixed方案


.fixed-top{position:fixed;bottom:auto;top:10;_position:absolute;_top:expression(eval(document.documentElement.scrollTop+10));} /* 頭部固定 */
.fixed-bottom {position:fixed;bottom:0px;top:auto;_position:absolute;_top:expression(eval(document.documentElement.scrollTop+document.documentElement.clientHeight-this.offsetHeight-(parseInt(this.currentStyle.marginTop,10)||0)-(parseInt(this.currentStyle.marginBottom,10)||0))); width:100px; height:100px; border:1px solid #f00;}/* 底部固定 */
* html,* html body {background-image:url(about:blank);background-attachment:fixed; }/* 修正IE6振動bug */


發佈了33 篇原創文章 · 獲贊 14 · 訪問量 12萬+
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章