Having trouble deselecting all jquery tabs
Posted
by Julian
on Stack Overflow
See other posts from Stack Overflow
or by Julian
Published on 2009-09-17T13:49:29Z
Indexed on
2010/05/12
8:04 UTC
Read the original article
Hit count: 315
I set up some jQuery tabs to start off with no tabs selected like this:
$('#tabs').tabs( { selected: -1 } );
Then I also have a separate link that when pressed needs to deselect all the tabs.
$("#deselectButton").click(function(){
$('#tabs').tabs( 'select' , -1 )
});
or
$("#deselectButton").click(function(){
$('#tabs').tabs( 'selected' , -1 )
});
The deselectButton click does deselect the tabs content, however the tabs title remains active with the class 'ui-tabs-selected ui-state-active'.
What is the correct way to deselect all the tabs?
© Stack Overflow or respective owner