X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Dev Questions (https://forum.x-cart.com/forumdisplay.php?f=20)
-   -   Resize thumbnails with GD (https://forum.x-cart.com/showthread.php?t=43719)

Vetrivel 12-23-2008 12:11 AM

Re: Resize thumbnails with GD
 
Hi,
This is because there is no $tmbn_url
Try to add it .
Quote:

Originally Posted by inboxnews
This works great with everything except Download Expander. Download Expander calls the following:

HTML Code:

<a href="product.php?productid={$product.productid}">{include file="product_thumbnail.tpl" productid=$product.productid image_x=$product.image_x image_y=$product.image_y product=$product.product}</a>&nbsp; </td>

Unfortunately, the above code displays no image :(, however, everything else seems to work just fine. Thanks for the post!


xplorer 12-24-2008 02:24 AM

Re: Resize thumbnails with GD
 
Quote:

Originally Posted by am2003
1. Maybe I am not happy by the results of your default values for the unsharp mask effect. Can we control the values the "unsharp mask" filter effect inside the script (Amount, Radius, Threshold)?



Yes, you can change the values by editing "include/lib/phpunsharmask.php" file. Search for the following string:
PHP Code:

function UnsharpMask($img$amount 120$radius 0.4$threshold 1)    { 



Quote:

Originally Posted by am2003
2. Did you use Unsharp Mask for PHP (http://vikjavev.no/computing/ump.php)?


Yes.

ADDISON 12-24-2008 02:31 AM

Re: Resize thumbnails with GD
 
xplorer: is it a way to configure those values in the Admin? A form inside the Mod?

xplorer 12-24-2008 02:56 AM

Re: Resize thumbnails with GD
 
Quote:

Originally Posted by am2003
xplorer: is it a way to configure those values in the Admin? A form inside the Mod?


No. The only way to change these parameters is editing the file I mentioned

ADDISON 12-24-2008 02:58 AM

Re: Resize thumbnails with GD
 
Maybe someone will customize the script and have this feature available for an easy configuration.

chris.barber 01-11-2009 02:27 PM

Re: Resize thumbnails with GD
 
I seem to be having trouble with this, I have performed the steps several times but it just doesn't seem to be working, not sure what else to try, I have tried placing the imagcache folder in different places but to no avail.

The instructions are so simple but it just doesn't seem to work.

JWait 01-12-2009 04:38 AM

Re: Resize thumbnails with GD
 
Quote:

Originally Posted by chris.barber
I seem to be having trouble with this, I have performed the steps several times but it just doesn't seem to be working, not sure what else to try, I have tried placing the imagcache folder in different places but to no avail.

The instructions are so simple but it just doesn't seem to work.


You might try checking your spelling. It is imagecache, not imagcache.

chris.barber 01-12-2009 09:03 AM

Re: Resize thumbnails with GD
 
Nice spot but I only spelt it wrong here.

chris.barber 01-12-2009 01:00 PM

Re: Resize thumbnails with GD
 
OK, so I found the problem

{if $config.Appearance.show_thumbnails eq "Y"}<img{if $id ne ''} id="{$id}"{/if} src="imager.php/product_thumb.jpg?width={$image_x}&amp;image={$tmb n_url}" alt="{$product|escape}"{if $show_border eq "Y"} class="ProductBorder"{/if} />{/if}

This line had a / before imager.php so read src="/imager.php/product_thumb.jpg, I removed the leading / and all is working fine now.

Great mod, will really help me as I have 1000s of products.

pfarcus 01-16-2009 08:35 AM

Re: Resize thumbnails with GD
 
cool mod, I think its working, I saw a bunch of small files in my imagecache folder.

Couple questions for all you smart people in here:
Is there a way to just get rid of the option of a "product image" since the product thumbnail upload does everthing and there is no need for a thumb and a product upload?

This one I really need:
Can we cap the max image size either height or width so ALL the product images would be same height? (or width) that shows up in the main product details page? I'm afraid some of these providers are going to upload huge images. (too large on screen) Need to have it re-make them to a uniform size. (I think 4.2 can do this, can we do it in 4.1.11 somehow?

This would be huge for me, very much appreciate your thoughts on this.


All times are GMT -8. The time now is 09:02 PM.

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