Output more than one image per product on list (category page) of Magento.

by Comments closed In: Magento

Output more than one image per product on list

If you have used the same products CSV in multiple time through Importer, then it will be show additional images for product page. If not production site, then you can clean the products media data and re-import it. Please check product in admin panel, and check which images are selected after product import. Read about How to Delete Products in Magento

NOTE : Please take the database and media backup.

Output more than one image per product on list





























//get images for product
$product = Mage::getModel('catalog/product')->load($_product->getId());
$helper = Mage::Helper('catalog/image');
foreach ($product->getMediaGalleryImages() as $image) {
    echo "helper('catalog/image')->init($this->getProduct(), 'thumbnail', $image->getFile())->resize(243) . "' />";
}
?>

Categories