ie6, ie7, ie8 perfectly support position:fixed ultimate solution_Experience exchange

WBOY
Release: 2016-05-16 12:03:41
Original
2013 people have browsed it

ie6 does not support position:fixed. There are many solutions on the Internet. Some of them are successfully debugged on ie6 and ie7, but they do not work on ie8. The div layer still floats following the scroll bar. The following summarizes the methods, which can be used in ie6. The debugging was successful on both ie7 and ie8, and when the page scroll bar scrolls, the effect is quite good, and the div layer does not flicker.

Copy code The code is as follows:


css:

Copy code The code is as follows:

.fixed{
position:fixed; / *For other browsers such as Firefox,*/
Top: 700px;/*Ibid 同 同*/
Width: 30px;
Height: 30px;
Cursor: Pointer;
Display: none;
}
.ie{ _position: absolute;
_clear: both;
_top:expression(eval(document.compatMode &&
document.compatMode=='CSS1Compat' )                                                                                documentElement                                                                                                                                           . .clientHeight-this.clientHeight) - 1); }
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template