Added for loop for multiple images.