Need currently selected tab ID for jQuery tabs -


I know that I can get an indicator of the currently selected tab, but I can somehow get the ID ( ui.panel.id if it was started by a tab event ... but is not currently in the selected tab)? I do not want to use the index because I can not use style markup because of changing tabs because they can turn into future releases. Is there any way to do this? If not, can I use the index to use it in some way (perhaps by accessing the panel object first)? Any other ideas?

You can use to target visible panels:

  $ ("# tab .ui-tabs-panel: visible"). Attr ("id");  

It is worth noting that you can retrieve the active tab from:

  $ ( "# Tabs"). Tabs ({active: function (Event, UI) {console.log (ui.newPanel [0] .id);}});  

Comments

Popular posts from this blog

c# - How to capture HTTP packet with SharpPcap -

php - Multiple Select with Explode: only returns the word "Array" -

php - jQuery AJAX Post not working -