I\'m having difficulty implementing an accordion effect on three different tables using jQuery and I could use some assistance. Right now it works o.k. When I click on the h
i added a fade effect. Check it - http://jsfiddle.net/XE6AG/1/
$(function() {
$(".research tr:not(.accordion)").hide();
$(".research tr:first-child").show();
$(".research tr.accordion").click(function(){
$(this).nextAll("tr").fadeToggle();
});
});
this one is faster - http://jsfiddle.net/XE6AG/2/
//this is fast
$(function() {
$(".research tr:not(.accordion)").hide();
$(".research tr:first-child").show();
$(".research tr.accordion").click(function(){
$(this).nextAll("tr").fadeToggle("fast");
});
});
this one is really really slow - http://jsfiddle.net/XE6AG/3/
//this is fast
$(function() {
$(".research tr:not(.accordion)").hide();
$(".research tr:first-child").show();
$(".research tr.accordion").click(function(){
$(this).nextAll("tr").fadeToggle("fast");
});
});
you could also add easing to it for example - http://jsfiddle.net/XE6AG/4/.