Contributions
Better image upload features
This contribution gives you the following features:
- Larger uploaded product images will be resampled for best fit within 1024 x 1024 pixels (Changeable).
- Uploads new product images to a separate folder. (catalog/images/ becomes catalog/images/products instead.)
- Saves new product images by datetime as filename (20090608-102450.jpg) instead of wacky original filename.
- Easily enable watermarking for all uploaded product images.
- Marks uploaded product images as temp files until changes are confirmed (i.e. _tmp20090608-102450.jpg).
That way orphan images from canceled changes can easily be deleted in catalog/images/products/.
Caution! This may collide with other image management contributions.
Expand All / Collapse All
Due to the many features added, and not being able to change the main description, the addon has has moved.
Fresh new thread:
http://addons.oscommerce.com/info/7589
Dummy file attached
Full package!
An error was found in the instructions chapter 3.4.2. Thank you crish.
tep_href_link(DIR_WS_IMAGES . $product_info['products_image'])
*** should instead be ***
tep_href_link(DIR_WS_IMAGES . $image)
I have installed this twice now, everything is displayed in the database and shows fine in the admin side, but after adding the code (2 edits) in the product info, the extra images display as thumbnails but when you hit the popup to enlarge only the first image will display! (not the extra images)
Is this missing code in the product_info.php?
Is code needed in the popup_image.php also?
Please fix!
Empty attachment!
There were two separate sql queries in step 1.1. When executing them at the same time an error was returned.
Added a ';' at the end of the first query so the second query would run without a problem.
Full package
Duplicate entry in instructions removed:
*** On line ~1134, find ***
echo tep_draw_hidden_field('products_image', stripslashes($products_image_name));
*** After that, add ***
// BOF: [TiM's osC Solutions] Better image upload features
echo tep_draw_hidden_field('products_extra_images', stripslashes($products_extra_images_names));
echo tep_draw_hidden_field('delete_extra_images', stripslashes(((is_array($HTTP_POST_VARS['delete_extra_images'])) ? implode(';', $HTTP_POST_VARS['delete_extra_images']) : false)));
// EOF: [TiM's osC Solutions] Better image upload features
FULL PACKAGE!
Full package!
This big update brings multiple product images. Here is a total summary of the contribution:
* Resampling
Larger uploaded product images will be resampled for best fit within 1024 x 1024 pixels (Adjustable in admin panel).
* Multiple product images
Upload almost an unlimited amount of extra product images.
* Dedicated folder
Uploads new product images to a separate folder. (catalog/images/ becomes catalog/images/products/ instead.)
* SEO filenames
Saves new product images by SEO friendly filename (Ex. 451-iPod_nano.jpg) instead of wacky original filename.
* Watermarking
Easily enable watermarking for all uploaded product images through admin panel.
* Temporary uploads
Marks uploaded product images as temp files until changes are confirmed (i.e. _tmp923467897.jpg).
That way orphan images from canceled changes can easily be deleted in catalog/images/products/.
* SQL code contained one parenthesis too much in column set_function for keys WATERMARK_POSITION_H and WATERMARK_POSITION_H.
Full package
Same as previous release, but previous instructions lacked code in chapter 3.2:
...
} else {
$products_image_name = (isset($_POST['products_previous_image']) ? $_POST['products_previous_image'] : '');
}
break;
Based on the previous update by menelrana (which was in french and had fatal errors).
+ Adjust maximum width and height of uploaded images in admin panel.
+ Enable/Disable watermarking of uploaded images in admin panel.
+ Translates foreign characters in SEO friendly image filename.
+ Set image filename type of uploaded images in admin panel to either Standard, SEO friendly or products_model.
Full package!
In configuration images you can use and configure Watermark with some options previously in code
You can also set image size
Full package
* Saves new product images by SEO friendly filename (Ex. 451-iPod_nano.jpg) instead of old method for using date for unique name.
Caution: If you implented the previous version, you need to undo the changes from step 2.1 in the previous version's instructions.
Full package
I messed up naming the oldskool variable right,
$HTTP_FILES_VARS should be $HTTP_POST_FILES.
Updated package.
This contribution gives you the following features:
- Larger uploaded product images will be resampled for best fit within 1024 x 1024 pixels (Changeable).
- Uploads new product images to a separate folder. (catalog/images/ becomes catalog/images/products instead.)
- Saves new product images by datetime as filename (20090608-102450.jpg) instead of wacky original filename.
- Easily enable watermarking for all uploaded product images.
- Marks uploaded product images as temp files until changes are confirmed (i.e. _tmp20090608-102450.jpg).
That way orphan images from canceled changes can easily be deleted in catalog/images/products/.
Caution! This may collide with other image management contributions.
Note: Contributions are used at own risk.