Finished O'Reilly Network Article

Whew, just finished and pushed my O'Reilly Network article out to the O'Reilly publishers; that was ALOT of work.

The article is titled "AJAX: How to Handle Bookmarks and Back Buttons." Here's a sneak peak on the intro; you'll have to wait until O'Reilly publishes the article to see the full thing ;)

"This article presents an open source JavaScript library that finally brings bookmarking and back button support to AJAX applications. By the end of this tutorial developers will have a solution to an AJAX problem that not even Google Maps or Gmail possesses: robust, usable bookmarking and back and forward behavior that works exactly like the rest of the web.

"AJAX: How to Handle Bookmarks and Back Buttons" discusses the significant issues that AJAX applications currently face with bookmarks and the back button; delivers an open source library created exclusively for this article that solves these problems; and presents serveral working examples.

The principal discoveries of the framework presented in this article are two-fold. First, we use a hidden HTML form to allow for a large transient session cache of client-side information which is robust against navigation to and away from the page. Second, we use a combination of hyperlink anchors and hidden iframes to intercept and record browser history events, tying into the back and forward buttons. Both techniques are wrapped with a simple JavaScript library to ease development."

Special thanks to everyone who reviewed the article and the Really Simple History framework: Michael Eakes, Jeremy Sevareid, David Barrett, Brendon Wilson, Dylan Parker, Erik Arvidsson, Adam Fisk, Alex Lynch, Joseph Hoang Do, Richard MacManus, Garret Wilson,
Alex Russell, Ray Baxter, Chris Messina, and David Weekly.

My next step is an article for the O'Reilly Network on long term permanent storage for AJAX applications. Like the last article, this will include an open source framework that allows AJAX applications to store data locally beyond the 4K limit of cookies. The basic approach is to use a hidden flash file that I wrap with a nice, hash table like JavaScript API; I've already prototyped the basic approach so I know it works. Internally, I use some special abilities in Flash to store arbitrary amounts of content locally long term. I think the example application in the article will be an simple AJAX word processor that can save files locally.

Comments

Jon said…
Regarding bookmarks, could you bookmark the state of a form? Could I use the back/forward buttons as undo/redo?

For instance: I fill in a form input and receive an ajaxian response. I change my input, receive a new response. I click on my back button and it rewrites the input value to my initial entry.

Maybe I need to wait for your article. :-)