cowboy / jquery-hashchange

This jQuery plugin enables very basic bookmarkable #hash history via a cross-browser HTML5 window.onhashchange event.
http://benalman.com/projects/jquery-hashchange-plugin/
GNU General Public License v2.0
1.21k stars 258 forks source link

accessing native window properties #9

Closed tbranyen closed 14 years ago

tbranyen commented 14 years ago

In blackberry 4.6 window[ str_location ][ str_href ] will result in a TypeError exception being raised. Custom properties added to the window object can be access in the hash notation, but native properties cannot.

cowboy commented 14 years ago

Lark, can you test and see which of these works?

window['location']['href']
window['location'].href
window.location['href']
window.location.href
location['href']
location.href
tbranyen commented 14 years ago

window['location']['href'] - fails window['location'].href - fails window.location['href'] - works window.location.href - works location['href'] - works location.href - works

cowboy commented 14 years ago

Changed window['location']['href'] to location.href to fix OMG FUN bug in blackberry 4.6. Closed by 400b3573ded39d4f5c10320de9ab43b08bbd2e1a.