區(qū)別IE6與FF:
background:orange;*background:blue;
區(qū)別IE6與IE7:
background:green !important;background:blue;
區(qū)別IE7與FF:
background:orange; *background:green;
區(qū)別FF,IE7,IE6:
background:orange;*background:green !important;*background:blue;
注:IE都能識(shí)別*;標(biāo)準(zhǔn)瀏覽器(如FF)不能識(shí)別*;
IE6能識(shí)別*,但不能識(shí)別 !important,
IE7能識(shí)別*,也能識(shí)別!important;
FF不能識(shí)別*,但能識(shí)別!important;
IE6 IE7 FF
* √ √ ×
!important × √ √
另外再補(bǔ)充一個(gè),下劃線"_",
IE6支持下劃線,IE7和firefox均不支持下劃線。
于是大家還可以這樣來(lái)區(qū)分IE6,IE7,firefox
: background:orange;*background:green;_background:blue;
注:不管是什么方法,書(shū)寫(xiě)的順序都是firefox的寫(xiě)在前面,IE7的寫(xiě)在中間,IE6的寫(xiě)在最后面。 |