JQuery gets the next element and all its children
How can I get the next div element and then all its children?
<div class="1"></div> <div class="2"> <div class="child1"></div> <div class="child2"></div> </div> <div class="3"> <div class="child1"></div> </div> so if $(this) is currently class 1, how can I get only class 2 and all its children. And I cannot refer to it by the name of my class, since I do not know what it is.
I basically try to combine these two operators in 1.
$(this).next('div').animate({height : 'toggle'}); $(this).next('div *').animate({height : 'toggle'}); +6