I decided to share a useful one-row snippet for web developers, which can save time and complexity using JavaScript that checks whether the browser that runs the code is MSIE
(Internet Explorer) and determine its version.
var MSIE = parseInt(window.navigator.userAgent.split("MSIE ")[1]) || false;
Now the MSIE
variable holds the version of the IE browser, or false
in case of other browser.
// i.e. atob() function supported on all browsers except IE9 and lower. if ( !MSIE || MSIE > 9 ) { alert(atob("WW91J3JlIEF3ZXNvbWUh")); }
Enjoy!
IE sucks! hope spartan will be better 🙂