开发者

Magento thumbnail issue getProductThumbnail()

I've installed Magento 1.5 on WAMP (at testdomain.localhost). I also installed the sample data.

I am using the default theme and have made no changes to it.

When I add one of the sample products to the cart and then click My Cart no items appear in the cart (even though in the menu it says there are items i开发者_开发知识库n it).

I tracked it down to app/design/frontend/base/default/template/checkout/cart/item/default.phtml. Nothing renders after the call to $this->getProductThumbnail()->resize(75);

It seems $this->getProductThumbnail() doesn't return anything but I can't figure out anything beyond that (noob and pulling my hair out..)

Any help appreciated!


-- THANK YOU matthew & clockworkgeek, it was the gd2 extension.. I had disabled it while debugging a WAMP issue. Doh!

Also increased memory_limit for good measure. Everything working perfectly now.


Check the pre-requisites for install. You may not have the GD library installed. This is necessary for resizing images.


Some other things to check:

  • The media and var folders, and all their sub-folders, need to be writable to the www process.
  • Working with large images requires lots of memory, ensure PHP has 256M to 512M for memory_limit in either php.ini or magento's .htaccess file.
  • After installing the sample data I find it helps to force the indexes to rebuild, go to Admin > System > Index Management to control that.
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜