CSS Hack :: Detecting IE11 using Js and CSS


JS

// Can also be used with $(document).ready()
jQuery(window).load(function() {
if(navigator.userAgent.match(/Trident.*rv:11\./)) {
jQuery('body').addClass('ie11');
}

});

CSS
And then in the css file things prefixed with

body.ie11 #some-other-div

 

Advertisements