Created
July 2, 2014 18:26
-
-
Save weblancaster/6789e76276801329893e to your computer and use it in GitHub Desktop.
javascript IE and IE11 detection
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function isIE() { return ((navigator.appName == 'Microsoft Internet Explorer') || ((navigator.appName == 'Netscape') && (new RegExp("Trident/.*rv:([0-9]{1,}[\.0-9]{0,})").exec(navigator.userAgent) != null))); } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment