Author Topic: [SOLVED] Images Aren't Resized after Installing Upgrade Patch  (Read 796 times)


  • Beginner
  • *
  • Posts: 19
I have had this issue since installing the 1.1.3 to 1.1.4 patch, and just now when I installed the 1.1.4 to 1.1.8 patch. Since the relevant file was overwritten, the issue returned. This is what happens:

After installing the patch successfully, instead of the thumbnail images being displayed on the category, category list, and product detail pages, the full-sized images are shown. They're so large they blow the rest of the page off the screen. Only existing images are affected; if new products/images are added, they display correctly.

I don't know if this problem is particular to something on my installation--it happens on three different VM installations--or if it's a bug in the code, but I know there are other threads about it and I thought it might help others if I created a specific thread for the issue.

The fix I use is to alter a single line of code in administrator / components / com_virtuemart / classes / ps_product.php. In 1.1.8, it's on line 1400, though in other versions you can just search for the affected line:

Code: [Select]
if(PSHOP_IMG_RESIZE_ENABLE == '1' && $resize==1) {
All it takes to fix it is to change the "and" (&&) to an "or" (||):

Code: [Select]
if(PSHOP_IMG_RESIZE_ENABLE == '1' || $resize==1) {
That solves the problem for me. The images display correctly as thumbnails and everything else seems to work fine.