区分 Firefox
@-moz-document url-prefix()
{#nav { display: block; }}
区分 Safari
@media screen and (-webkit-min-device-pixel-ratio:0)
{#nav { display: block; }}
区分 Opera
@media all and (-webkit-min-device-pixel-ratio:10000), not all and (-webkit-min-device-pixel-ratio:0)
{head~body #nav { display: block; }}
区分 IE
IE 7
html > body #nav
{*display: block;}
IE 6
body #nav
{_display: block;}
只针对IE6的HACK。
!important
width: 100px!important;
width: 80px;
IE6/IE77对FireFox
*+html 与 *html 是IE特有的标签,firefox 暂不支持。而*+html 又为 IE7特有标签。
#wrapper { width: 120px; }
*html #wrapper { width: 80px;}
*+html #wrapper { width: 60px;}