Image Optimization Add-on
Introduced in slscart version 10.15.0.
Description
Optimize an image in slscart. The images in general image, thumbnail, large, category, blog, and gallery directories can be optimized.
Only jpg and png images can be optimized.
There is no capability of telling whether an image has been optimized or not.
Provider
Currently, tinypng is used to optimize the images. Requires getting an API key. 500 optimizations/mo for free (last checked Sept 2024).
Setup
1. Go to this site: https://tinypng.com/developers
1. Enter your name and email address. The API key will be sent via email.
2. Under Storeadmin > Administration > Extra Settings enter in the Tinify key then click button 'Update Variables'.
How to use
1. Make sure the images that are optimized are backed up.
2. We'll use Large Image Directory as an example. Go ito Web Site > Images then select Large Image Directory from the dropdown then click 'Show Images' button.
3. There is an OP link by each image that can be optimized. Click on the OP link.
The file size, width, and height of the image is displayed along with up to four checkboxes. If
4. Check the boxes, if any, of the image attributes to preserve.
preserve location (jpg only)
preserve creation
preserve copyright
preserve GPS location
5. Click on Optimize button. It may take several seconds before the image is optimized.
The results of the image optimization process is displayed.
Tips
1. Don't optimize an image more than once. Currently, there is no way
to keep track of whether in image has been optimized. I suggest keep a
list of the ones optimized (you can keep it in Notes (under Website
Administration).
Or optimize the image then rename the image with a
-o after it. If the image is named bracelet.jpg then the optimized one
would be bracelet-o.jpg
Troubleshooting
Q: There is no place to enter API key under Extras.
The tinify library is not installed
The version of slscart is not 10.15.0 or later
Q: Optimize does not work.
- API key incorrect
- tinify library not installed
***