Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

'On The Fly' Auto Thumbnailer using GD Library 2.1


mloeffen

Recommended Posts

Hi,

 

Great contrib first off. I followed the instructions, and even went over them two more times and everything seems to work fine when it comes to uploading images and the creation of the thumbnails. Also the product listings show the "No Image" pic as a thumbnail. The problem I have run into is that when I click on the item that I have not added an image to and go to the details page the only thing that comes up is the date the product was added. None of the product details is displayed. This only happens on items that I have not added an image to and it should show the "No Image" pic but nothing shows.

 

Here is the website.

 

Any suggestions are greatly appreciated.

I can't see how this contribution would cause the symptoms you are experiencing. Maybe you have installed another contribution or messed up your site some other way. I doubt that it would be anything to do with this contrib.

Link to comment
Share on other sites

  • Replies 556
  • Created
  • Last Reply

Top Posters In This Topic

hello

 

tried to install on the fly auto thumbnailer and i worked fine untill i did something and suddenly both my admin and shop went totally bananas. have tried to step-by-step replace the files i've changed but still the same error shows:

 

shop:

 

Warning: mysql_connect(): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) in /hsphere/local/home/slimjim/karen.peterlundgren.se/catalog/includes/functions/database.php on line 19 Unable to connect to database server!

admin:

 

Warning: mysql_connect(): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) in /hsphere/local/home/slimjim/karen.peterlundgren.se/catalog/admin/includes/functions/database.php on line 19 Unable to connect to database server!

anyone had this problem?

if so, please help me...

 

/peter

I hope this is not still a problem for you.

 

If it is this is most likely something to do with your configure.php files having the wrong settings for your database.

Link to comment
Share on other sites

I can't see how this contribution would cause the symptoms you are experiencing. Maybe you have installed another contribution or messed up your site some other way. I doubt that it would be anything to do with this contrib.

 

Well I am using a template from templatemonster.com and I found that this bit of code was throwing a wrench in it.

<?php 
if (tep_not_null($product_info['products_image'])) { 
?>

 

If there was no image uploaded, it wouldn't show the details. I simply commented it out and now the no_image.jpg as well as the product details show up fine. So nope, it wasn't the contrib. Thanks anyway.

Link to comment
Share on other sites

Well I am using a template from templatemonster.com and I found that this bit of code was throwing a wrench in it.

<?php 
if (tep_not_null($product_info['products_image'])) { 
?>

 

If there was no image uploaded, it wouldn't show the details. I simply commented it out and now the no_image.jpg as well as the product details show up fine. So nope, it wasn't the contrib. Thanks anyway.

It is often the case that templates are not what one expects when they buy them as the creators usually don't care about the ramifications of their modifications on the stability of the system after you have made your purchase. I'm glad you managed to find the problem and now have a working site.

Link to comment
Share on other sites

Thank you psynatic. To simple.

Hi phpsurfer,

 

Do you mean the installation was easy?

Link to comment
Share on other sites

Hi All,

might anyone assist?

 

I run an almost clean MS2.2 (Got Admin Access, Easy Populate and STS). I installed this grat contrib but I got an issue.

When I click on thumbs they do not enlarge and I get back a JS script error (the ones you see bottom-left in Internet Explorer).

Also, I copied all the code of step 7 in the right position as it was on the readme file. I got an "unexpected } on line 197" when i was loading the catalog from the browser. So I removed that "}" And it works fine. Excpet for the popup windowses not diplaying.

 

Where am I wrong?

 

Thank you a Lot.

Link to comment
Share on other sites

Hi All,

might anyone assist?

 

I run an almost clean MS2.2 (Got Admin Access, Easy Populate and STS). I installed this grat contrib but I got an issue.

When I click on thumbs they do not enlarge and I get back a JS script error (the ones you see bottom-left in Internet Explorer).

Also, I copied all the code of step 7 in the right position as it was on the readme file. I got an "unexpected } on line 197" when i was loading the catalog from the browser. So I removed that "}" And it works fine. Excpet for the popup windowses not diplaying.

 

Where am I wrong?

 

Thank you a Lot.

 

A litte update: looks like that the problem is concerning STS. Its deactivation (pages to not uses STS's Templates) causes the pop-up to work correctly.

Tho I checked the template file I wasn't able to come out with a clue. I got no other JSs working there....Ideas?

Link to comment
Share on other sites

A litte update: looks like that the problem is concerning STS. Its deactivation (pages to not uses STS's Templates) causes the pop-up to work correctly.

Tho I checked the template file I wasn't able to come out with a clue. I got no other JSs working there....Ideas?

 

Ok forgive me to bother again: solved everything by adding a JS header to the template file.

 

One note though: the readme file of OTFAT presents in step 7 a "}" more than needed. output_html.php will complain about it if you do not remove that character on line 197.

 

bye all

Link to comment
Share on other sites

Hi All,

might anyone assist?

 

I run an almost clean MS2.2 (Got Admin Access, Easy Populate and STS). I installed this grat contrib but I got an issue.

When I click on thumbs they do not enlarge and I get back a JS script error (the ones you see bottom-left in Internet Explorer).

Also, I copied all the code of step 7 in the right position as it was on the readme file. I got an "unexpected } on line 197" when i was loading the catalog from the browser. So I removed that "}" And it works fine. Excpet for the popup windowses not diplaying.

 

Where am I wrong?

 

Thank you a Lot.

Can anyone confirm this please?

Link to comment
Share on other sites

  • 1 month later...

Hi all,

I found the following errors in my Server error_log.

PHP Warning:  %v%v() [<a href='function.%v'>function.%v</a>]: Invalid image dimensions in
/srv/www/vhosts/domainname.com/httpdocs/catalog/product_thumb.php on line 307, referer: http://www.domainname.com/
catalog/checkout_payment.php?osCsid=xyz

PHP Warning:  imagecolorallocate(): supplied argument is not a valid Image resource in
/srv/www/vhosts/domainname.com/httpdocs/catalog/product_thumb.php on line 310, referer: http://www.domainname.com/
catalog/checkout_payment.php?osCsid=xyz

PHP Warning:  imagefill(): supplied argument is not a valid Image resource in
/srv/www/vhosts/domainname.com/httpdocs/catalog/product_thumb.php on line 312, referer: http://www.domainname.com/
catalog/checkout_payment.php?osCsid=xyz

PHP Warning:  imagecolortransparent(): supplied argument is not a valid Image resource in 
/srv/www/vhosts/domainname.com/httpdocs/catalog/product_thumb.php on line 313, referer: http://www.domainname.com/
catalog/checkout_payment.php?osCsid=xyz

PHP Warning:  imagecopyresampled(): supplied argument is not a valid Image resource in 
/srv/www/vhosts/domainname.com/httpdocs/catalog/product_thumb.php on line 347, referer: http://www.domainname.com/
catalog/checkout_payment.php?osCsid=xyz

 

any idea what is wrong?

Link to comment
Share on other sites

Hi all,

I found the following errors in my Server error_log.

PHP Warning:  %v%v() [<a href='function.%v'>function.%v</a>]: Invalid image dimensions in
/srv/www/vhosts/domainname.com/httpdocs/catalog/product_thumb.php on line 307, referer: http://www.domainname.com/
catalog/checkout_payment.php?osCsid=xyz

PHP Warning:  imagecolorallocate(): supplied argument is not a valid Image resource in
/srv/www/vhosts/domainname.com/httpdocs/catalog/product_thumb.php on line 310, referer: http://www.domainname.com/
catalog/checkout_payment.php?osCsid=xyz

PHP Warning:  imagefill(): supplied argument is not a valid Image resource in
/srv/www/vhosts/domainname.com/httpdocs/catalog/product_thumb.php on line 312, referer: http://www.domainname.com/
catalog/checkout_payment.php?osCsid=xyz

PHP Warning:  imagecolortransparent(): supplied argument is not a valid Image resource in 
/srv/www/vhosts/domainname.com/httpdocs/catalog/product_thumb.php on line 313, referer: http://www.domainname.com/
catalog/checkout_payment.php?osCsid=xyz

PHP Warning:  imagecopyresampled(): supplied argument is not a valid Image resource in 
/srv/www/vhosts/domainname.com/httpdocs/catalog/product_thumb.php on line 347, referer: http://www.domainname.com/
catalog/checkout_payment.php?osCsid=xyz

 

any idea what is wrong?

Is GD available on your server?

Link to comment
Share on other sites

I'm having a quality problem. The thumbnails being generated are really chunky. Here's an example:

 

http://www.littleotsu.com/catalog/product_...19e50c9c7b5af5a

 

Any help is super appreciated. Thanks!

I'm experiencing the same sort of chunkiness on my site after installing the 'On the Fly' Auto Thumbnailer using GD Library...how abouts did you fix it? Thanks!

 

-Rick

Link to comment
Share on other sites

How can I make this so it only works on products and not my layout. My layout has some clear gif's and it makes these huge Image not found thumbnails for the all the corners etc. it's pretty scary looking.

Link to comment
Share on other sites

OK I FINALLY GOT SOMETHING HAPPENING AFTER READING TO PUT THE THUMBNAIL.PHP IN THE ROOT.

 

Now My Images Do Not Show Up.... BUT They are now being created in the IMAGES FOLDER. When I right click and VIEW IMAGE it shows me a link like this....

 

http://outdoorfurnacesupply.com/product_th...p;w=80&h=53

 

but does not display the image.....

 

maybe I need to have the complete path after thumb.php=

 

I don't know... Ill keep trying. ANY ADVICE?

 

Jay

Link to comment
Share on other sites

  • 2 weeks later...

I've modified code from ZenPhoto (another open source PHP project) to create an automatic thumbnail that is cropped to a square (or whatever size / dimensions you want). I don't have a ton of time to optimize the code or search for glitches but if anyone is interested in helping do that, I can send over what I have.

 

Currently, the thumbnail is called from the product listing page. The first time it's called, a new, square thumbnail image is added to a cache folder in "images." I know this goes against parts of the 'On the Fly' thumbnailer but maybe someone involved in that project would like to add the crop code to this contribution? There seems to be some interest in image cropping.

 

Please email me at liz [at] enesher [dot] com.

 

Thanks!

Liz

Link to comment
Share on other sites

  • 2 weeks later...
  • 3 weeks later...

Hi and thanks to everyone who's worked so hard to produce this contribution.

 

I just wanted to say that it worked perfectly on installation without any fiddling. The instructions were excellent. This is by far the most user-friendly, well-documented contribution I've ever installed.

 

Thanks a bunch.

Link to comment
Share on other sites

I searched the thread but couldn't unearth how to do what I need. Unless I'm overlooking some setting or post somewhere.

My problem is this:

My site has HUGE images that I'm scaling down with this contribution.

And the contribution works great, it creates the thumbnail that people can click to make larger.

The problem stems when they make it larger.

The large images are 1700 x 1280 and are still a bit big at that size for the "Click to enlarge" version.

I need an intermediate size that would show up when clicked to be enlarged, that can still be clicked one step further to become the massive size if one wishes to see the detail that much more.

Then clicked again to become intermediate, clicked again to become massive, so on and so forth, or x'd to close the popup.

 

Would someone be kind enough to help me out or point me in the right direction?

Thanks in advance.

Link to comment
Share on other sites

I searched the thread but couldn't unearth how to do what I need. Unless I'm overlooking some setting or post somewhere.

My problem is this:

My site has HUGE images that I'm scaling down with this contribution.

And the contribution works great, it creates the thumbnail that people can click to make larger.

The problem stems when they make it larger.

The large images are 1700 x 1280 and are still a bit big at that size for the "Click to enlarge" version.

I need an intermediate size that would show up when clicked to be enlarged, that can still be clicked one step further to become the massive size if one wishes to see the detail that much more.

Then clicked again to become intermediate, clicked again to become massive, so on and so forth, or x'd to close the popup.

 

Would someone be kind enough to help me out or point me in the right direction?

Thanks in advance.

 

bump

Link to comment
Share on other sites

Hi!

 

I installed this package.

Nothing special, the images and thumbnails in image/ directory (i do not use the catalog dir), but OSC doesn't show my images.

I checked the source, and i see, the image is the product_thumb.php?params...

Ok, i copied this src URL into a browser, and very intresting things happens.

 

IE never shows it, just give me the 304 error.

Firefox: show once, and if i refresh then not, if i refresh it shows again, and then not, etc...

 

I set the code: $is304 = true; to $is304 = false;

and both of the browsers show me the thumbnails.

 

what could be the wrong ?

 

in the apache error log:

[Tue Aug 21 14:13:36 2007] [error] [client 195.**.**.***] FastCGI: comm with server "/var/www/php-cgi/php5" aborted: error parsing headers: duplicate header 'Status', referer: xxxxxxxxxxx.zzzzzzzzz.yy

 

Thanks: Lolka

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...