4

For few products images are visible but for some products images are not visible. After spending few hours i found that for the products whose images are missing is because their images are not getting cached, i cross checked the cache directory under media/catalog/product/cache

Images are not getting cached for few products only and for others images gets cached.

777 permission is given to all media directories. These products are created programmatically

  • 2
    Check for all browsers/ check your memory limit for php_value memory_limit 256M – TBI Infotech Jul 31 '14 at 5:58
  • TBI, add this as an answer, good idea! – Fabian Blechschmidt Jul 31 '14 at 7:23
  • @DeepakMallah Thanks for the confirmation its added as an answer – TBI Infotech Jul 31 '14 at 9:36
5

Check for all browsers/ check your memory limit for php_value memory_limit 256M

1

If the above solution don't work (for me it didn't worked), try to upload a smaller image file. I first uploaded a 650k image file and the product image was shown in admin but nothing shown in front. I replaced with a smaller file size of about 150k and now the product image is shown in product page.

1

To be able to run on the server properly I had to increase memory limit to 512 MB.

I had a similar problem, that some images are not loaded on server. Server is run with PHP 7 RC and memory limit 256 MB. With PHP 5.6 and memory limit 256 MB on my local there was no problem with images. Just be aware that PHP 7 RC you may need more memory.

1

I also got the same problem because of some extension which i have used to zoom the product image.

This problem automatically solved when i removed those extensions (uninstall the extension which you have used to zoom the product image, the problem will be there even you disable the extension. So don't disable it, uninstall it directly)

to uninstall the extensions -

Go to the System -> Mangento Connect -> Magento connect manager -> Manage Existing Extensions

select the unwanted extensions & hit commit changes & refresh the page

Problem will be solved...

0

Rename the cache folder in media/catalog/product and refresh your website.

0

One more scenario could be

memory_limit should not be in GBs(memory_limit 1G). It should be either in KB's(memory_limit 1000KB) or MB's(memory_limit 256M).

Because open file lib/Varien/Image/Adapter/Gd2.php and search for a function _convertToByte Here Magento is checking only for M and KB.

if (stripos($memoryValue, 'M') !== false) {
    return (int)$memoryValue * 1024 * 1024;
} elseif (stripos($memoryValue, 'KB') !== false) {
     return (int)$memoryValue * 1024;
}
return (int)$memoryValue;
0

I was facing the same issue, I imported the products using csv, my images are displayed in admin but not on frontend.

When I update the product manually from admin, product images start showing that means there was something missing in db that is stopping images to get displayed.

I debug with db in "CATALOG_PRODUCT_ENTITY_VARCHAR" table and found attribute_id 155, 156 missing in imported file, 155 is product_page_type=default & 156 is product_image_size = 0, you can eav_attribute table for 155, 156.

As soon as I added these attributes in csv in additional_attribute column, and imported the csv again.

then reindex the magento, clear cache and everything works good.

Thanks Rahul

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.