X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   Image Size (https://forum.x-cart.com/showthread.php?t=1336)

cartesio 01-31-2003 04:05 AM

Image Size
 
Like change thumbnail image size of x cart

example: like every image of product tumbnail have this size 100 x 150

where is the .php or .tpl i take modify ?

Thanks

shan 01-31-2003 04:30 AM

try this one

skin1/product_thumbnail.tpl

cartesio 01-31-2003 06:11 AM

thank you,

Yes i test this modification

But when i set (example)
$image_x ne 100
and
$image_y ne 150
the image distort

the mystere ... if set 70 the image not distort

note my image as good set up
canvas 100*150

shan 01-31-2003 06:16 AM

If your thumbnails are all the right size to start with (100x150) then you could change your skin1/product_thumbnail.tpl to this


Code:

{* $Id: product_thumbnail.tpl,v 1.4 2002/09/05 12:43:21 zorg Exp $ *}
{if $config.General.show_thumbnails eq "Y"}[img]../image.php?productid={$productid}[/img]{/if}


In other word just remove the part that sets the size

dez 02-26-2003 12:39 PM

Change thumbnail size
 
I have pictures that are 300 x 225 (I know a little large).
I want the thumbnails to be about half size.

The full image is too big and the small thumbs are too small
to see the details of my products. I need an in between.

i see that in / product_thumbnail.tpl there are some x and y variables
but I am not sure how to change these.

Since I've the same question and I don't see anyone replay, I thought I post this again.

original post:

http://forum.x-cart.com/viewtopic.php?t=2147&highlight=productthumbnail+tp l

ATKOgirl 02-26-2003 01:28 PM

Hi,

You may be better off just setting the image x to 100 and not setting the y. This will maitain the image aspect ratio, resizing in aspect based on the width. If you set both x and y, and the settings do not maintain the original image aspect ratio, the image will be distorted.

Hope that helps,

ATKOgirl

BoomBoomBap 02-26-2003 06:34 PM

Incidentally, I chatted with Dez and managed to solve this problem.

Go into the page customer/main/products.tpl and change the product_thumbnail include to something like this:


Code:

{include file="product_thumbnail.tpl" productid=$products[product].productid image_x=150 image_y=150 product=$products[product].product}

where
x is width
y is length

As ATKO girl mentioned settings the y value isn't recommended unless all thumnails are exactly the same dimension. In this case remove image_y=150


Hope this helps...


All times are GMT -8. The time now is 05:23 AM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.