jQuery UI选中后退按钮历史记录

Ces*_*era 33 jquery user-interface tabs history back

有没有人能够使用后退按钮获得jQuery UI Tabs 3(最新版本)?

我的意思是如果用户点击后退按钮,他们应该转到页面上先前访问过的选项卡,而不是其他页面.

历史插件听起来像它可以工作,但我似乎无法使其与Ajax加载选项卡一起工作.

如果有人设法完成这项工作,我们将非常感谢,谢谢!

Jus*_*ade 38

我也碰到了这个.使用jquery地址插件非常简单http://www.asual.com/jquery/address/

标签的演示似乎有点过于复杂.我这样做了:

$('document').ready(function() {
    // For forward and back
    $.address.change(function(event){
      $("#tabs").tabs( "select" , window.location.hash )
    })

    // when the tab is selected update the url with the hash
    $("#tabs").bind("tabsselect", function(event, ui) { 
      window.location.hash = ui.tab.hash;
    })
});
Run Code Online (Sandbox Code Playgroud)


Gar*_*ett 9

我建议看看这个:http: //www.asual.com/jquery/address/它允许你进行深度链接,以及你的AJAX调用.