I want to get the index of the current tab using jQuery UI
tabs: especially when the show
or select
events are fired i want to know the tab thay are referred is this possible?
If you want to know tabindex of current element in HTML, then you should use document. activeElement. tabIndex .
try: $('#tabs'). on("click", "a", function - instead.
You can use this to find
var $tabs = $('#tab').tabs();
var selected = $tabs.tabs('option', 'selected');
From JQuery 1.9 on
var $tabs = $('#tab').tabs();
var selected = $tabs.tabs('option', 'active');
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With