I want to turn off JavaScript using JavaScript (and/or jQuery) code, only if the page is viewed in IE7.
How can this be done?
Would be grateful for the magic code snippet!
I want to turn off JavaScript using JavaScript (and/or jQuery) code, only if the page is viewed in IE7.
How can this be done?
Would be grateful for the magic code snippet!
Use conditional comments.
http://msdn.microsoft.com/en-us/library/ms537512(v=vs.85).aspx
You can check
if ($.browser.msie && $.browser.version < 8)
and not run your code.You can´t turn JavaScript off. You can however exclude IE7 by using Downlevel-revealed Conditional Comments.