How to reduce the size of the product image in the basket virtuemart_2 ? By default, preview is displayed, but it is large.

 <span class="cart-images"> <?php if (!empty($prow->image)) echo $prow->image->displayMediaThumb('', false); ?> </span> 

    2 answers 2

    Everything turned out to be much simpler: added to vm.css

     .cart-images img{ width: 100px; } 

      I suspect you want something like this:

       str_replace('img', 'img width="100"', $subject)$prow->image->displayMediaThumb('', false)); 

      Just add the width to HTML or CSS.

      • `<span class =" cart-images "> <? php if (! empty ($ prow-> image)) {echo str_replace ('img', 'img width =" 100 "', $ subject) $ prow-> image-> displayMediaThumb ('', FALSE); }?> </ span> ` - Sergey
      • I correctly inserted your code? - Sergey
      • In HTML or CSS, add the width value - and where to add? - Sergey
      • That's right in theory - KeyGenQt