javascript - Detect whether a page is entered through history.back -
when return previous page through history.back(), page not newly loaded. instead, displayed left. efficient , avoids dribbling in of images.
however, want run function when page entered via history.back() synchronise page calling history.back(). there event firing in called page when entered in way [i.e. history.back()]?
note: have hack using setinterval polls re-entry, think ugly. tried popstate did not fire.
you can use
especially
history.adapter.bind(window,'statechange',function()
it fires on every state change ('back' well).
Comments
Post a Comment