Reputation: 87
i have grid-view display 3 images the first 1 was deleted i want to loop through grid-view images and put it's src into array but ignore images that deleted this image display what i really encountered
Upvotes: 0
Views: 1059
Reputation: 92903
var arr = [];
$('#container').find('img,[type=image]').each(function() {
arr.push(this.src); // stores the absolute src
// arr.push($(this).attr('src')); // stores the original HTML attribute
});
Upvotes: 2