jquery ui tabs support for the browers back button
I have a jquery driven web application and a particular page on the site, I use the jquery ui tab control - http://jqueryui.com/demos/tabs/
This enables me to have a page where content separated by tabs.
This works well without issue.
I now need to add support for the browsers back button - so if I have 4 tabs - A, B, C, D and currently on tab C. When I press the back button of the browser, I would like to return to tab B and press it again, return to tab A. How can I integrate this in to the jquery ui tabs?
Secondly, I when the browsers back button is pressed, along with moving to the previo开发者_StackOverflow社区us tab, I would like for the page NOT to refresh if possible. So that the movement for the user seemless and close to instant. How possible is this?
If I understand the question correctly, you can use the jQuery BBQ plugin by Ben - http://benalman.com/projects/jquery-bbq-plugin/
Similar to your requirement is the demo that Ben provides at http://benalman.com/code/projects/jquery-bbq/examples/fragment-basic/
Hope it helps.
You're confusing the browser back button's role. It is meant go back in browsing history, not to cycle thru your tabs. You need to add a prev/next link on you page to cycle thru your tabs.
精彩评论