The plugins site is currently in development.
We've been looking to provide a higher-quality, spam-free experience at the plugins site for some time, and a major error on our part forced us to shut down the current site before we could put the new one in place. We are developing a new site, and you can follow along with its development on GitHub. For more information about this transition, including steps you can take as a plugin author to prepare, please read our post about what's going on.
jHistory
Allows for browser forward/back button support through the use of hidden IFRAME. The user will not be hindered by any location.href changes and odd links that appear in the browser's location bar. This does not allow bookmarking.
The main advantage of this over the current History plugin, the jQuery UI History plugin or any javascript-based browser history functionality that harnesses the Location Hash fragment method is specifically for e-commerce driven AJAX functionality. This hides individual history fragments from the user's view and prevents specific fragments from being bookmarked.
This supports the storage of any javascript object for each history event fired and the automatic execution of a callback function if the forward/back button was hit. This is well suited for e-commerce AJAX applications for handling such events as adding a product to the cart with a history event written and allowing the user to hit the back button to then remove the product from the cart or reinstate the shopping cart from the previous history event.
To use:
- Simply include op top of the jQuery core to automatically load the jHistory plugin:
<script language="JavaScript" type="text/javascript" src="jquery.js"></script>
<script language="JavaScript" type="text/javascript" src="jquery.history.js"></script> - To save an event in history with the current state of the object you want saved:
$.history( currentObject ); - You must declare a callback function to be fired upon forward or back button being clicked to handle the new incoming stored history object:
$.history.callback = function ( reinstate, cursor ) {
alert('now the value is: ' + reinstate);
};
