Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Thumbnail creation


spottedhaggis

Recommended Posts

I made the mistake of uploading the images in their original size during the adding of the 200 or so products, and now realise I should have used a thumbnail package.

 

I have manually created the thumbnails, and would like to know how and where I can alter the path so that the thumbnail image is displayed, and when clicked the original image is displayed?

 

Can anyone help me with this.

Born - Scotland

Location - Kent, England

Job - hunting for one

Link to comment
Share on other sites

I made the mistake of uploading the images in their original size during the adding of the 200 or so products, and now realise I should have used a thumbnail package.

 

I have manually created the thumbnails, and would like to know how and where I can alter the path so that the thumbnail image is displayed, and when clicked the original image is displayed?

 

Can anyone help me with this.

 

 

1. Make a folder called thumbs inside the imagefolder

2. Upload your new thumbnails

3. Edit the image paths in all the files where thumbnails is shown.

 

Like this: (From products_new.php)

tep_image(DIR_WS_IMAGES . 'thumbs/' . $products_new['products_image'],

Link to comment
Share on other sites

This is now what I have in Products_new file, but it still loads the entire image as a small version in the system?

 

tep_image(DIR_WS_IMAGES . 'thumbs/' . $new_products['products_image']) . '</a><br><a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $new_products['products_id']) . '">' . $new_products['products_name'] . '</a><br>' . $currencies->display_price($new_products['products_price'], tep_get_tax_rate($new_products['products_tax_class_id'])));

Born - Scotland

Location - Kent, England

Job - hunting for one

Link to comment
Share on other sites

products_new.php (Catalog folder)

 

           <td width="<?php echo SMALL_IMAGE_WIDTH + 10; ?>" valign="top" class="main"><?php echo '<a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $products_new['products_id']) . '">' . tep_image(DIR_WS_IMAGES . 'thumbs/' . $products_new['products_image'], $products_new['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a>'; ?></td>

Link to comment
Share on other sites

When you have done the code change, go to http://www.dragonfly-dreams.net/products_new.php to see it in effect

 

If everything is working as its supposed to, then next you will have to edit all the other .php files which shows thumbnails.

Link to comment
Share on other sites

You can also do it the other way around, then you only have to edit 1 file , products_info.php .

 

Move all the main product pictures into a new folder name..lets say, big , then put all the thumbnails in your main image folder.

 

Change the pop-up picture path in products_info.php to get the image from the big folder.

Link to comment
Share on other sites

Thats more or less what I have now done, oh and hi again

 

Just to let you know, the following additions are complete

 

Guestbook added.

 

Comments and feedback form (used a blog script for this)

 

More information in contacts page as suggested.

Born - Scotland

Location - Kent, England

Job - hunting for one

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...