When I create loop inside a loop and want to access this element inside the second loop, I referenced to this link(Targeting $(this) within nested for each loops in jQuery). I use
var $this = $(this);
Where $this references first loop and $(this) references second. But I need one more inside the second loop and need to access another "this" object of third loop. I need to have something like this
$('.section1').each(function(){
var $this = $(this);
$this.find('div[class = "text_question"]').each(function(){
$(this).find('label').each(function() {
//I want to access the element of this loop (each label object's text)
});
}
How can I achieve that?