jquery-hashchange icon indicating copy to clipboard operation
jquery-hashchange copied to clipboard

$.browser was removed

Open matrym opened this issue 12 years ago • 4 comments

http://jquery.com/upgrade-guide/1.9/#jquery-browser-removed

hashchange depends on it.

matrym avatar Mar 23 '13 05:03 matrym

:+1:

niftylettuce avatar Apr 13 '13 09:04 niftylettuce

One way around this, to detect IE only, is to use IE's conditional compiler comments. For more information, see http://msdn.microsoft.com/en-us/library/ie/121hztk3(v=vs.94).aspx

Instead of testing for this:

$.browser.msie && !supports_onhashchange ...

test for an msie variable (or whatever you want to call it), that is only set to true if running in IE:

var msie = false;
/*@cc_on
    msie = true;
@*/

msie && !supports_onhashchange ...

BillyRayPreachersSon avatar Apr 24 '13 16:04 BillyRayPreachersSon

This worked fine for me

navigator.userAgent.match(/msie/i) && !supports_onhashchange && (function(){

Neil-Partridge avatar May 16 '13 12:05 Neil-Partridge

I think #30 is a better solution.

konsumer avatar Sep 03 '13 04:09 konsumer