CSS hack notes
记下æ?¥å¤‡æŸ¥ï¼Œä¸?æ–å¢žåŠ ä¸ã€‚çœ?å¾—æ¯?次去找了。
IE䏿¨¡æ‹Ÿposition:fixed效果,最好和æ?¡ä»¶æ³¨é‡Šé…?å?ˆä½¿ç”¨
html, body{
height: 100%;
overflow: auto;
}
div.fixed {
position: absolute;
}
�件注释:
<!--[if lt IE 7]>
<link rel="stylesheet" href="ie.css" type="text/css" />
<![endif]-->
这个是clear floatå…ƒç´ çš„æ–¹æ³•ï¼š
.clearfix:after {
content: ".";
display: block;
height: 0;
clear: both;
visibility: hidden;
}
.clearfix {display: inline-table;}
/* Hides from IE-mac \*/
* html .clearfix {height: 1%;}
.clearfix {display: block;}
/* End hide from IE-mac */
�有IE/Win ��的写法:
/* Holly Hack: Hide From IE5/Mac \*/
* html .yourclass {
}
/* Holly Hack: End Hide From IE5/Mac */
ä¿®æ£IEwinçš„3px margin bug,适用于两列并排的情况
#floatbox {
float: left;
width: 123px;
}
p{
margin-left:123px;/* for none IE/win browsers */
}
/*\*/
* html #floatbox {
margin-right:-3px;
}
* html p {
height: 1%;
margin-left: 0;
}
/**/
* html #floated-image {
/* if the floater itselft is a image or other replaced element */
margin: 0 -3px; ma\rgin: 0;
}
IE5/Win Only Styles
/* IE5/Win Only Styles
----------------------------------------------- */
@media tty {
i{content:"\";/*" "*/}} @import url('ie5win.css'); /*";}
}/* */