2 Product Thumbnail image sizes Mod [finished]
Joseph Kwan:
This hack is for vm1.0.x. In the new version, the hack should be done by modifying the appropriate template.
ejohnson:
Quote from: Joseph Kwan on June 09, 2009, 12:59:46 PM
This hack is for vm1.0.x. In the new version, the hack should be done by modifying the appropriate template.
Thanks for the reply Joseph. Can you expand a little on what you meant by "modifying the appropriate template"?
Would I be tackling this mod the wrong way if I edited pretty much the same files you did to get the mod running on vm1.0.x? Obviously the syntax would have to comply with the way the code/syntax has gone in Joomla1.5/vm1.1.x.
Thanks for any advice you have.
Joseph Kwan:
You can follow the steps as outlined. But I think the hack is an overkill just to display a second thumbnail of different size. There are too many changes needed. As you can see this is a very old thread and may be useful by that time only.
VM has a dynamic image generation system. You should take advantage of this to generate the second thumbnail. Actually, you can have as many thumb sizes as you wish.
The url for your image should be:
/components/com_virtuemart/show_image_in_imgtag.php?filename=your_image_filename&newxsize=90&newysize=90
Change 90 to the size you need and put this url in the location where you want the image to show in your browse or flypage template.
eg you can use
<img src="/components/com_virtuemart/show_image_in_imgtag.php?filename=<?php echo $product_full_image ?>&newxsize=250&newysize=250" />
to display a thumb image of size 250x250 px.
ejohnson:
Quote from: Joseph Kwan on June 11, 2009, 15:52:02 PM
You can follow the steps as outlined. But I think the hack is an overkill just to display a second thumbnail of different size. There are too many changes needed. As you can see this is a very old thread and may be useful by that time only.
VM has a dynamic image generation system. You should take advantage of this to generate the second thumbnail. Actually, you can have as many thumb sizes as you wish.
The url for your image should be:
/components/com_virtuemart/show_image_in_imgtag.php?filename=your_image_filename&newxsize=90&newysize=90
Change 90 to the size you need and put this url in the location where you want the image to show in your browse or flypage template.
eg you can use
<img src="/components/com_virtuemart/show_image_in_imgtag.php?filename=<?php echo $product_full_image ?>&newxsize=250&newysize=250" />
to display a thumb image of size 250x250 px.
GAH ... thanks. Lifesaver ...
Navigation
[0] Message Index
[*] Previous page