How do you iterate over a group of selected jQuery objects so that you can execute jQuery functions on each object individually?
<div class = "foobar"> abc </div>
<div class = "foobar"> 123 </div>
<div class = "foobar"> abc123 </div>
I can select a group:
var foobarObjects = jQuery('.foobar')
But how would you go through each jQuery object in foobarObject and manipulate each separately? I thought I could use it jQuery().each, but it only allows me to work with DOM objects, not jQuery objects. I also tried a for loop in conjunction with a function jQuery().eq(i), but this is like combining elements together.
source
share