$.browser has been eliminated in Jquery1.9 version:
Determine browser type:
$.browser.mozilla = /firefox/.test(navigator.userAgent.toLowerCase());
$.browser.webkit = /webkit/.test(navigator.userAgent .toLowerCase());
$.browser.opera = /opera/.test(navigator.userAgent.toLowerCase());
$.browser.msie = /msie/.test(navigator.userAgent.toLowerCase ());
The expression after the equal sign returns true/false, which can be directly used to replace the original $.browser.msie, etc.
Check whether it is IE6:
/ / Old
if ($.browser.msie && 7 > $.browser.version) {}
// New
if ('undefined' == typeof(document.body.style.maxHeight) ) {}
Check if it is IE 6-8:
if (!$.support.leadingWhitespace) {}
Statement:The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn