17,230
edits
mNo edit summary |
No edit summary |
||
Line 16: | Line 16: | ||
// hide the content | // hide the content | ||
$('.tabtarget | $('.tabtarget .tabcontent').hide(); | ||
// select a tab | // select a tab | ||
Line 44: | Line 44: | ||
// onclick event | // onclick event | ||
$(this).on( 'click', function() { | $(this).on( 'click', function() { | ||
$('#'+target+' | $('#'+target+' .tabcontent').hide(); | ||
$('.tabset[data-tab-target="'+target+'"][data-tab-selector="'+selector+'"] .tab2').removeClass( 'active' ); | $('.tabset[data-tab-target="'+target+'"][data-tab-selector="'+selector+'"] .tab2').removeClass( 'active' ); | ||
$(this).addClass( 'active' ); | $(this).addClass( 'active' ); |