I\'m new to jquery and was wondering: is a simple way to detect whether a browser is Internet Explorer 6 or below?
If ActiveXObject exists and XMLHttpRequest does not, it's IE6:
ActiveXObject
XMLHttpRequest
/* IE6 Check */ (!!window.ActiveXObject && !window.XMLHttpRequest) ? true : false;
In IE7, it would be:
(!!window.ActiveXObject && !!window.XMLHttpRequest) ? true: false;
References