I have a for loop in my jquery script
var images[];
for(i=0;i<$('#imageHolder div').length;i++)
{
images.push($('#imageHolder div:eq( i )').attr('alt'));
console.log($('#imageHolder div:eq(i )').attr('alt'));
}
I am not able to add the elements to the array and the console.log says undefined in the console. What is my possible error and how that can be corrected?