5
votes

I'm uploading products to my Magento store but products are not being displayed.

I can upload the image using the admin area and when managing my products I can see the images there, but once I go to the front end I just get the Magento logo where the product image should appear.

This has been happening since my server migration so I'm not sure if its related or not.

7

7 Answers

7
votes

There are many things that could be causing this issue, but here's a few things for you to look into:

  1. On the Product Information page in your admin backend, under 'Images', make sure the radio buttons have an image selected for 'Base Image', 'Small Image', 'Thumbnail', and that they aren't 'Excluded'

  2. Make sure the product images exist under /media/catalog/product/ (relative to your document root)

  3. Make sure the /media directory is in your Apache web server's group (usually 'www-data' or 'httpd'). Magento also needs to be able to write to this directory, so you can run this command to set those permissions:

    sudo chmod -R 775 /path/to/magento/media
    
  4. In System->Configuration->General->Web, make sure "Base Media URL" is correct under both "Secure" and "Unsecure"

6
votes

Just rename .htaccess to .htaccess-old inside media directory in Magento Root Directory.

3
votes

You need to do the following to get this right:

  1. Recursively change permissions -r or via ftp set media folder to 777
  2. Make sure your server has curl, image gd enabled and refresh magento cache
0
votes

Just adding more information to help: if your SELINUX is enabled, you need additional setup. Here you can find some information http://www.magentocommerce.com/knowledge-base/entry/ce18-and-ee113-installing#install-prereq-selinux

0
votes

try this code:- Might be you are not adding below line:-

$_product=Mage::getModel("catalog/product")->load($_product->getId());
0
votes

Even though late, Hope it will help for someone

If its still not showing even after all the above tweaks. Try to reduce the size of the image to few KBs and try. It worked for Me.:)

0
votes

For me the issue was php7.0-gd extension. Once I installed it image appears without a problem.

sudo apt-get install php7.0-gd

sudo service apache2 restart