Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

binding hashchange event in IE7 issue

I am experiencing some issues binding to the hashchange event in Internet Explorer 7. All other versions of Internet Explorer - ie. 8 & 9 work without issue.

My code is:

 $(window).bind('hashchange', function (e) { alert('hash changed'); });

When the hash of the url changes in Firefox, IE8, IE9 I get the alert box, but in IE7, nothing happens.

Anyone experience this before?

like image 368
amateur Avatar asked Jul 26 '11 16:07

amateur


1 Answers

Pretty sure IE6 and IE7 don't support it natively. Did you try using Ben Alman's jquery BBQ script which fixes this?

like image 128
meder omuraliev Avatar answered Sep 23 '22 01:09

meder omuraliev