jpcody + hashchange 1
A Saner HTML5 History App
december 2010 by jpcody
This app is a demo that shows a saner use of HTML5 History Management and Hashchange than the approach implied by the standard. In this case, the app is built to respond to the URL, not the other way around. In this way, the app can always enter the same, unique state, based only on the contents of the URL. This is essentially like making a RESTful client application. The app listens to changes to the URL through the "pathchange" event, which is provided by a jQuery plugin, jquery.pathchange.js. If your browser supports it, this app should be making use of HTML5 History Management and the HTML5 Hashchange event to provide the notifications. If your browser does not support it, some URLs will require a new page load, but the app will still enter the correct state. All of this means that browser back/forward, refresh, and bookmarking is supported throughout the app.
javascript
urls
hashchange
december 2010 by jpcody