Browsersniffing with CSS

After some research I found the follow css code for sniffing out browsers and emailclients through css. /*Internet Explorer*/
<!--[if IE 7]>
.glue{color: black;}
<![endif]-->

<!–[if IE 6]>
.glue{color: blue;}
<![endif]–>

/* outlook 2007*/

<!--[if gte mso 9]>
.glue{color: aqua;}
<![endif]-->

/* Firefox */
@-moz-document url-prefix() {

.glue { color: red; }
}

/* Opera */
@media all and (-webkit-min-device-pixel-ratio:10000), not all and (-webkit-min-device-pixel-ratio:0) { .glue { color: yellow; }
}

Leave a Comment