How to get current tab title which i named in Jquery Tabs UI

后端 未结 6 811
温柔的废话
温柔的废话 2021-01-19 23:06

I\'m using http://jqueryui.com/demos/tabs/#manipulation. I want to get an title of current selected tab which I earlier named (e.g. from a href). How to get it?

I tr

6条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2021-01-19 23:55

    Thanks I was struggling with this code.

    Now I've used thiscode in my program. Working like this.

    $('#tabs').click('tabsselect', function (event, ui) {
        var selectedTab = $("#tabs").tabs('option','selected');
        alert("selectedTab===>" +  $($("#tabs li")[selectedTab]).text());
    });
    

提交回复
热议问题