Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

jQuery select all elements inside particular parent elements

I need to loop through all table elements, somewhere keeping an index and then loop through all elements inside those tables. Idea is to add information into database about elements inside tables together with their table index.

like image 666
spacemonkey Avatar asked Nov 10 '09 20:11

spacemonkey


1 Answers

$('table').each(function(index) {
    $(this).find('*').each(function() {
        /* do magic */
    });
});
like image 130
reko_t Avatar answered Oct 20 '22 16:10

reko_t



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!