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

Please post your admin settings.

 

Make sure all sub-dirs of catalog/images/ are 777 too.

Edited by psynaptic
Link to comment
Share on other sites

  • Replies 556
  • Created
  • Last Reply

Top Posters In This Topic

Goto your admin section. That .sql file you ran on your database created a page under Configuration called Thumbnails, it should be directly under Images.

 

Copy the settings out exactly as they are in there. It might give me an idea what could be wrong.

Link to comment
Share on other sites

Rich,

 

 

 

This is........... catalog/

 

admin 755

download 755

images 777

includes 755

pub 755

account.php 11.2Kb 644

account_edit.php 11.8Kb 644

account_history.php 7.4Kb 644

account_history_info.php 11.3Kb 644

account_newsletters.php 7.0Kb 644

account_notifications.php 11.0Kb 644

account_password.php 8.0Kb 644

address_book.php 8.8Kb 644

address_book_process.php 17.8Kb 644

advanced_search.php 10.1Kb 644

advanced_search_result.php 14.2Kb 644

checkout_confirmation.php 15.7Kb 644

checkout_payment.php 17.0Kb 644

checkout_payment_address.php 21.5Kb 644

checkout_process.php 15.9Kb 644

checkout_shipping.php 19.8Kb 644

checkout_shipping_address.php 21.6Kb 644

checkout_success.php 6.7Kb 644

conditions.php 3.4Kb 644

contact_us.php 6.3Kb 644

cookie_usage.php 3.7Kb 644

create_account.php 22.0Kb 644

create_account_success.php 3.8Kb 644

download.php 4.1Kb 644

index.php 18.5Kb 644

info_shopping_cart.php 1.4Kb 644

login.php 10.2Kb 644

logoff.php 3.7Kb 644

password_forgotten.php 6.2Kb 644

popup_image.php 1.5Kb 644

popup_search_help.php 1.4Kb 644

privacy.php 3.5Kb 644

product_info.php 12.6Kb 644

product_reviews.php 11.0Kb 644

product_reviews_info.php 9.4Kb 644

product_reviews_write.php 11.0Kb 644

product_thumb.php 13.9Kb 755

products_new.php 6.8Kb 644

redirect.php 2.8Kb 644

reviews.php 7.3Kb 644

shipping.php 3.5Kb 644

shopping_cart.php 11.2Kb 644

specials.php 5.6Kb 644

ssl_check.php 3.2Kb 644

stylesheet.css 5.7Kb 644

tell_a_friend.php 10.0Kb 644

 

and this is......catalog/Admin/

 

backups 777

graphs 777

images 777

includes 755

backup.php 22.5Kb 644

banner_manager.php 25.9Kb 644

banner_statistics.php 7.4Kb 644

cache.php 4.8Kb 644

categories.php 61.0Kb 644

configuration.php 8.7Kb 644

countries.php 12.3Kb 644

currencies.php 17.5Kb 644

customers.php 36.7Kb 644

define_language.php 7.7Kb 644

file_manager.php 18.6Kb 644

geo_zones.php 23.9Kb 644

index.php 14.7Kb 644

invoice.php 7.0Kb 644

languages.php 18.8Kb 644

mail.php 9.6Kb 644

manufacturers.php 15.5Kb 644

modules.php 12.8Kb 644

newsletters.php 20.8Kb 644

orders.php 26.7Kb 644

orders_status.php 14.2Kb 644

packingslip.php 4.6Kb 644

popup_image.php 1.4Kb 644

products_attributes.php 51.5Kb 644

products_expected.php 6.3Kb 644

reviews.php 18.4Kb 644

server_info.php 5.2Kb 644

specials.php 17.8Kb 644

stats_customers.php 5.0Kb 644

stats_products_purchased.php 4.9Kb 644

stats_products_viewed.php 4.8Kb 644

tax_classes.php 10.8Kb 644

tax_rates.php 13.0Kb 644

whos_online.php 8.8Kb 644

zones.php 11.1Kb 644

 

 

And this is...... catalog/images

 

banners 777

default 777

dvd 777

gt_interactive 777

hewlett_packard 777

icons 777

infobox 777

mail 777

matrox 777

microsoft 777

sierra 777

account_notifications.gif 1.7Kb 644

account_orders.gif 2.3Kb 644

account_personal.gif 2.5Kb 644

arrow_down.gif 386 bytes 644

arrow_east_south.gif 433 bytes 644

arrow_green.gif 69 bytes 644

arrow_south_east.gif 434 bytes 644

box_products_notifications.gif 1.4Kb 644

box_products_... ...ns_remove.gif 1.5Kb 644

box_write_review.gif 1.0Kb 644

category_dvd_movies.gif 928 bytes 644

category_hardware.gif 1.7Kb 644

category_software.gif 1.1Kb 644

checkout_bullet.gif 533 bytes 644

dj020500.jpg 19.9Kb 777

dj021000.jpg 14.4Kb 777

header_account.gif 439 bytes 644

header_cart.gif 535 bytes 644

header_checkout.gif 605 bytes 644

manufacturer_canon.gif 1.1Kb 644

manufacturer_fox.gif 2.5Kb 644

manufacturer_... ...teractive.gif 1.4Kb 644

manufacturer_... ...t_packard.gif 640 bytes 644

manufacturer_logitech.gif 1.0Kb 644

manufacturer_matrox.gif 904 bytes 644

manufacturer_microsoft.gif 667 bytes 644

manufacturer_sierra.gif 1.1Kb 644

manufacturer_warner.gif 2.1Kb 644

no_image.jpg 4.4Kb 644

oscommerce.gif 3.6Kb 644

pixel_black.gif 35 bytes 644

pixel_silver.gif 35 bytes 644

pixel_trans.gif 43 bytes 644

stars_1.gif 145 bytes 644

stars_2.gif 151 bytes 644

stars_3.gif 147 bytes 644

stars_4.gif 145 bytes 644

stars_5.gif 127 bytes 644

subcategory.gif 308 bytes 644

subcategory_action.gif 1.3Kb 644

subcategory_action_games.gif 1.2Kb 644

subcategory_cartoons.gif 1.6Kb 644

subcategory_cdrom_drives.gif 1.6Kb 644

subcategory_comedy.gif 1.4Kb 644

subcategory_drama.gif 1.5Kb 644

subcategory_graphic_cards.gif 2.0Kb 644

subcategory_keyboards.gif 1.2Kb 644

subcategory_memory.gif 2.4Kb 644

subcategory_mice.gif 1.1Kb 644

subcategory_monitors.gif 1.4Kb 644

subcategory_printers.gif 1.1Kb 644

subcategory_s... ...e_fiction.gif 1.2Kb 644

subcategory_simulation.gif 1.4Kb 644

subcategory_speakers.gif 2.0Kb 644

subcategory_strategy.gif 1.6Kb 644

subcategory_thriller.gif 1.2Kb 644

table_background_account.gif 979 bytes 644

table_backgro... ...ress_book.gif 1.5Kb 644

table_background_browse.gif 1.2Kb 644

table_background_cart.gif 1.4Kb 644

table_background_checkout.gif 1.4Kb 644

table_backgro... ...firmation.gif 1.2Kb 644

table_backgro... ...ontact_us.gif 788 bytes 644

table_background_default.gif 877 bytes 644

table_background_delivery.gif 847 bytes 644

table_background_history.gif 1.2Kb 644

table_background_list.gif 1.0Kb 644

table_background_login.gif 1.3Kb 644

table_backgro... ..._on_board.gif 4.2Kb 644

table_backgro... ...forgotten.gif 1.3Kb 644

table_background_payment.gif 1.1Kb 644

table_backgro... ...ducts_new.gif 688 bytes 644

table_background_reviews.gif 1.1Kb 644

table_backgro... ...views_new.gif 1.6Kb 644

table_background_specials.gif 1.1Kb 644

THUMBNAIL_PAT... ...umb_59x80.jpg 839 bytes 644

THUMBNAIL_PAT... ...umb_59x80.jpg 796 bytes 644

THUMBNAIL_PAT... ...umb_57x32.gif 618 bytes 644

Link to comment
Share on other sites

I didn't mean do that.

 

Have you seen the admin section of your store yet? When you install osCommerce you get a page with two links; one takes you to your catalog and the other to your administration area where you setup your store (add products etc.).

 

You need to go in there and locate the page that has the settings for the Thumbnails. Write out those settings for us to see.

 

If you don't know this basic stuff I would suggest starting again with a fresh install of osCommerce and learning the basics before trying more advanced stuff.

 

Having said that I hope there isn't a problem with my instructions. Has anyone else managed to get version 2.2 working?

 

I'm going to sleep now so speak tomorrow.

Link to comment
Share on other sites

Rich,

 

Sorry for the mis-understanding, I've looked at so many files, folders and admin sections in the last couple days ( I had a brain freeze :-" ). I do know the basics and been to the oscommercs admin panel many, many times. I've installed sts4.4 , pink skin and EasyPopulate with no problems. With that being said, I really appreciate the time you have givin me.

 

This is what I got from.....administaration/configuration/thumbnails

 

Use Resampling true

Use True Colour true

Output GIF as JPEG false

Background matte colour (GIF as JPEG) 255,255,255

Cache images on the server true

Thumbnail path (I'm using default dir.... catalog/images/)

Cache images in browser true

JPEG Compression Level 70

Allow larger false

Show original true

Link to comment
Share on other sites

Rich,

 

Sorry for the mis-understanding, I've looked at so many files, folders and admin sections in the last couple days ( I had a brain freeze :-" ). I do know the basics and been to the oscommercs admin panel many, many times. I've installed sts4.4 , pink skin and EasyPopulate with no problems. With that being said, I really appreciate the time you have givin me.

 

This is what I got from.....administaration/configuration/thumbnails

 

Use Resampling true

Use True Colour true

Output GIF as JPEG false

Background matte colour (GIF as JPEG) 255,255,255

Cache images on the server true

Thumbnail path (I'm using default dir.... catalog/images/)

Cache images in browser true

JPEG Compression Level 70

Allow larger false

Show original true

No problem.

 

That shows you have the default settings and everything looks fine to me.

 

I didn't have a problem when I tried to install on a fresh osCommerce apart from forgetting to chmod the image dirs. I can't think of anything off the top of my head that could be causing the problem.

 

Please, can anyone else confirm that the install instructions actually work?

Link to comment
Share on other sites

Rich,

 

Sorry for the mis-understanding, I've looked at so many files, folders and admin sections in the last couple days ( I had a brain freeze :-" ). I do know the basics and been to the oscommercs admin panel many, many times. I've installed sts4.4 , pink skin and EasyPopulate with no problems. With that being said, I really appreciate the time you have givin me.

 

This is what I got from.....administaration/configuration/thumbnails

 

Use Resampling true

Use True Colour true

Output GIF as JPEG false

Background matte colour (GIF as JPEG) 255,255,255

Cache images on the server true

Thumbnail path (I'm using default dir.... catalog/images/)

Cache images in browser true

JPEG Compression Level 70

Allow larger false

Show original true

Did you check your server's GD capabilities? If not, please use the file gdtest.php and copy the output here.

 

I'm sorry you seem to be having problems. Did anyone else manage to install this?

Link to comment
Share on other sites

Rich,

 

 

Yes, I ran the gdtest.php. I even went over all my steps today, it all looks good. I will try 1 more time (Clean Install), then I guess I will have to uninstall it. If this does'nt work for me, do you have any other recommendations on a Thumbnail Add-on to use?

 

 

 

This is the gdtest.......

 

GD is supported by your server!

 

GD Version Yes

FreeType Support Yes

FreeType Linkage Yes

T1Lib Support No

GIF Read Support Yes

GIF Create Support Yes

JPG Support Yes

PNG Support Yes

WBMP Support Yes XBM

Support Yes

JIS-mapped Japanese Font Support No

 

Thanks a bunch,

 

Kevin

Link to comment
Share on other sites

Rich,

Yes, I ran the gdtest.php. I even went over all my steps today, it all looks good. I will try 1 more time (Clean Install), then I guess I will have to uninstall it. If this does'nt work for me, do you have any other recommendations on a Thumbnail Add-on to use?

This is the gdtest.......

 

GD is supported by your server!

 

GD Version Yes

FreeType Support Yes

FreeType Linkage Yes

T1Lib Support No

GIF Read Support Yes

GIF Create Support Yes

JPG Support Yes

PNG Support Yes

WBMP Support Yes XBM

Support Yes

JIS-mapped Japanese Font Support No

 

Thanks a bunch,

 

Kevin

Let me try following my instructions on a clean install and I'll get back to you.

Link to comment
Share on other sites

Let me try following my instructions on a clean install and I'll get back to you.

 

For what it is worth, I have just installed the latest version of this contribution and I am experiencing the same issues as taboofantasys. I am anxious to see what you might come up with. This contribution appears to be very powerful, so I would like to make it work. Thanks!

Link to comment
Share on other sites

Let me try following my instructions on a clean install and I'll get back to you.

I just installed the 2.2 package on a clean install of osCommerce and everything went well. I can see the images and their locations show they are being generated by Auto Thumbnailer:

 

catalog/product_thumb.php?img=images/dvd/under_siege2.gif&w=130&h=104

 

It might be some other contribution causing the problem. You may have missed a crucial part of the installation although I doubt that because there's not much to go wrong. Did you replace the correct tep_image() function all the way to it's close? For example:

////
// The HTML image wrapper function
 function tep_image($src, $alt = '', $width = '', $height = '', $parameters = '') {
if ( (empty($src) || ($src == DIR_WS_IMAGES)) && (IMAGE_REQUIRED == 'false') ) {
  return false;
}

// alt is added to the img tag even if it is null to prevent browsers from outputting
// the image filename as default
$image = '<img src="' . tep_output_string($src) . '" border="0" alt="' . tep_output_string($alt) . '"';

if (tep_not_null($alt)) {
  $image .= ' title=" ' . tep_output_string($alt) . ' "';
}

if ( (CONFIG_CALCULATE_IMAGE_SIZE == 'true') && (empty($width) || empty($height)) ) {
  if ($image_size = @getimagesize($src)) {
	if (empty($width) && tep_not_null($height)) {
	  $ratio = $height / $image_size[1];
	  $width = intval($image_size[0] * $ratio);
	} elseif (tep_not_null($width) && empty($height)) {
	  $ratio = $width / $image_size[0];
	  $height = intval($image_size[1] * $ratio);
	} elseif (empty($width) && empty($height)) {
	  $width = $image_size[0];
	  $height = $image_size[1];
	}
  } elseif (IMAGE_REQUIRED == 'false') {
	return false;
  }
}

if (tep_not_null($width) && tep_not_null($height)) {
  $image .= ' width="' . tep_output_string($width) . '" height="' . tep_output_string($height) . '"';
}

if (tep_not_null($parameters)) $image .= ' ' . $parameters;

$image .= '>';

return $image;
 }

Edited by psynaptic
Link to comment
Share on other sites

For what it is worth, I have just installed the latest version of this contribution and I am experiencing the same issues as taboofantasys. I am anxious to see what you might come up with. This contribution appears to be very powerful, so I would like to make it work. Thanks!

 

Also, I just got the following error when I tried to run the minor sql update:

"An error occurred while processing auto thumbnailer admin update.sql SQL file.

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '; DELETE FROM configuration WHERE configuration_key='THUMBNAIL_T"

Link to comment
Share on other sites

For what it is worth, I have just installed the latest version of this contribution and I am experiencing the same issues as taboofantasys. I am anxious to see what you might come up with. This contribution appears to be very powerful, so I would like to make it work. Thanks!

I don't know what you guys are doing!

 

I just went through the 2.2 instuctions on a fresh install osCommerce and everything is working perfectly. Apart from forgetting to install the .sql that comes with the original contibution instead of just the update (I should have made the update encompass everything from the initial one) everything works as expected. I can see all images and they are clearly being generated by product_thumb.php.

 

Are you all sure you have images and all sub-dirs to chmod 777? You can do this easily on the command line using chmod -R 777 /path/to/images/

Link to comment
Share on other sites

Also, I just got the following error when I tried to run the minor sql update:

"An error occurred while processing auto thumbnailer admin update.sql SQL file.

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '; DELETE FROM configuration WHERE configuration_key='THUMBNAIL_T"

Did you copy and paste into terminal by any chance?

Link to comment
Share on other sites

Rich,

 

hmmmmmmm!

 

I just did a clean install of everythig, no other addons but the thumbnailer and oscommerce. I get no error on any part of this installation. All permissions are set to (777). Still same red X.

 

 

 

..This is what I see when I, right click and ck. properties of the Red X image in the store front.....

 

https://st144.startlogic.com/~taboofan/osCo...oduct_thumb.php?

 

...also ck. here you might see somthingI dont.....

 

http://taboofantasys.com/osCommerce/catalog/

 

there is only 1 pic /w the red X, I only uploaded 1 to keep it simple.

Link to comment
Share on other sites

Did you copy and paste into terminal by any chance?

 

I just downloaded the txt file from the contribution website and use the run sql module. I ran the original sql script fine, the update is the one that doesn't work for me.

Link to comment
Share on other sites

You seem to be forcing SSL for your entire site. This will increase your page load times so it's not recommended. You only need to use SSL when customer's details need encrypting. I don't know if being on a shared host has anything to do with this problem but just to make sure please disable your SSL.

Link to comment
Share on other sites

I just downloaded the txt file from the contribution website and use the run sql module. I ran the original sql script fine, the update is the one that doesn't work for me.

Please try to run the update .sql file using PHPMyAdmin and see if the error occurs there. Just import the file and click 'Go'.

Link to comment
Share on other sites

Rich,

 

 

I think it is a path error, because as you saw on my webpage, the the prog worked as far as making the thumb size correct, and it made a thumbnail image in my catalog/images/thumbnail/ ...folder, and when I click the thumb preview in my filemanager it is a perfect little thumb pic. Where is the spot to change/make the path to the thumbnail? In admin/config/thumbnail ?

 

 

...as far as the ssl, it must be an auto set, because I didnt change anything. Any idea of where I can disable this?

 

...You seem like a mature adult, I would be willing to hand over my info so you can log my account, and then I will change it when your done.....That is if you are willing and feel comfortable with that. May you can see whats going on.

 

 

Till then .ty :thumbsup:

Link to comment
Share on other sites

Rich,

 

 

After looking at your profile, I realize you do this for a living and that time is money, and stuff isnt free. I would be more than happy to compensate you for your time. This should be the last mod, befor I start to upload items. I going to be over 15000 items, when its all said and done.

Link to comment
Share on other sites

Rich,

I think it is a path error, because as you saw on my webpage, the the prog worked as far as making the thumb size correct, and it made a thumbnail image in my catalog/images/thumbnail/ ...folder, and when I click the thumb preview in my filemanager it is a perfect little thumb pic. Where is the spot to change/make the path to the thumbnail? In admin/config/thumbnail ?

...as far as the ssl, it must be an auto set, because I didnt change anything. Any idea of where I can disable this?

 

...You seem like a mature adult, I would be willing to hand over my info so you can log my account, and then I will change it when your done.....That is if you are willing and feel comfortable with that. May you can see whats going on.

Till then .ty :thumbsup:

You're better off learning to do it yourself.

 

Open your catalog/includes/configure.php and change ENABLE_SSL to false. The paths are also in there but since your other images are fine that won't be the problem. I can't think what it could be.

Link to comment
Share on other sites

Ok, Rich

 

I really want to thank you for your help. I guess I'm at a dead end (I've tried it all). I'm going to try to find another Thumb mod.

 

Have a great day,

 

Kevin

 

 

 

PS: If anyone gets this figured out look hit me up, or I will keep cking back here. I really like this one.

Link to comment
Share on other sites

It works perfectly on the default images. It's something to do with the one you added.

 

I sent you a PM by the way.

Edited by psynaptic
Link to comment
Share on other sites

Rich,

 

Thank you, and I got your pm.

 

 

I got 1 quick question about this step?

 

 

Step #8 - Admin image size settings

Note: Before you change the settings, write down the current values so you can restore them in case of an error!

 

Go to the admin section of your store (Configuration -> My Store -> Images) and set:

 

all image width and height values to a value greater than zero

calculate image sizes to true.

 

What do you set them too?

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...