开发者

How to use jQuery tabs to link to a URL rather than load a tab using Html.ActionLink?

开发者 https://www.devze.com 2023-03-13 22:25 出处:网络
<ul> <li><a href=\"#tabs-1\">Tab1</a></li> 开发者_Python百科<li>@Html.ActionLink(\"Test\", \"Test\")</li>
<ul>
    <li><a href="#tabs-1">Tab1</a></li>
  开发者_Python百科  <li>@Html.ActionLink("Test", "Test")</li>   
</ul>


From the docs you can learn how to use the select callback for that.

$('#example').tabs({
    select: function(event, ui) {
        var url = $.data(ui.tab, 'load.tabs');
        if( url ) {
            location.href = url;
            return false;
        }
        return true;
    }
});
0

精彩评论

暂无评论...
验证码 换一张
取 消