ElEditors, Interface administrators, Administrators
85,546
edits
mNo edit summary |
mNo edit summary |
||
Line 1: | Line 1: | ||
/* Return whether a particular class is used************************************** | /* Return whether a particular class is used************************************** | ||
* Description: Uses regular expressions and caching for better performance. | * Description: Uses regular expressions and caching for better performance. | ||
Line 13: | Line 9: | ||
}; | }; | ||
})(); | })(); | ||
addOnloadHook(function(){ | addOnloadHook(function(){ | ||
$('div.tabdiv > div').hide(); | $('div.tabdiv > div').hide(); | ||
Line 19: | Line 15: | ||
$('div.tabdiv > ul > li:first').removeClass('inactive').addClass('active'); | $('div.tabdiv > ul > li:first').removeClass('inactive').addClass('active'); | ||
$('div.tabdiv > ul > li').click(function(){ | $('div.tabdiv > ul > li').click(function(){ | ||
$ | var target = $(this).find('> a:first').attr('href'); | ||
$(this).parent().find('> li').addClass('inactive').removeClass('active'); | |||
$(this).parent().find('>li'). | $(this).addClass('active').removeClass('inactive'); | ||
$(this).removeClass('inactive'). | $(target).show(); | ||
}); | }); | ||
}); | }); | ||
/* | |||
* | addOnloadHook(function($){ | ||
addOnloadHook(function($) { | |||
return function() { | return function() { | ||
$('.tabdiv > div').hide(); | $('.tabdiv > div').hide(); | ||
Line 52: | Line 47: | ||
} | } | ||
}(jQuery)); | }(jQuery)); | ||
*/ | |||
/****************************** Slides JS ******************************/ | /****************************** Slides JS ******************************/ | ||
addOnloadHook(function(){ | addOnloadHook(function(){ |