Jquery How to use history plugin?
- by Martijn
In my web application I am using ajax and now I'd like the back and forward browser buttons to work. So I went looking for a jquery history plugin and found this one: http://stilbuero.de/jquery/history
In my code I use a function to load a page:
function loadDocument(id, doc) {
$("#DocumentContent").show();
// Clear dynamic menu items
$("#DynamicMenuContent").html("");
$("#PageContent").html("");
// Load document in frame
$("#iframeDocument").attr("src", 'ViewDoc.aspx?id=' + id + '&doc=' + doc + '');
// Load menu items
$("#DynamicMenuContent").load("ShowButtons.aspx");
}
As you can see I want my pages to load within an Iframe. Can someone tell me how I can use a history plugin so that the brwoser buttons will work? I don't really care which plugin it is, as long as the browser buttons work. I prefer an easy to use plugin.