This is what I meant by stating "inform the user on-screen of a duplicate name situation". I think just simply not allowing it without at LEAST an on-screen message for the store admin as to why the image was not processed is necessary.. This gives the shop admin an opportunity to correct the product name to fall inline with the requirements.
which is why naming based solely on product name is a bit tricky and will require some thought.. Because even if the product names were not duplicated (and eg the image names will not be duplicates either) the way that Zen "recognizes" additional product images will still present a challenge that needs to be resolved.
Using one of my clients for example she has product names like this:
- Indian Remy Machine Weft Soft Fro Texture, 4 oz.
- Indian Remy Machine Weft Bodywave Texture, 4 oz.
- Indian Remy Machine Weft Kinky Straight Texture, 4 oz.
- Indian Remy Machine Weft Silky Straight Texture, 4 oz.
Images named based on these product names will probably be interpreted by Zen Cart as additional images for these products. So all four of these products could end up with 1 main product image and additional images from the other products. Not good..
It seems that the way to resolve this is to assign some kind of unique value to each product which is then appended to the beginning of image names. Elegant?? IMHO, I think this is a very elegant option as it solves several different issues at once.. IMHO something like this is necessary unless you want to get into re-writing the way Zen Cart recognizes additional product images..Appending a unique value to the beginning of each image name ends up satisfying the requirement needed to prevent "accidental" additional images, minimize errors due to duplicate image names, and incorporates the product name into the image name (for those who insist that this makes a difference for SEO). I think this is a doable solution.
So using my client's product names as an example, in my thinking the final image name could end up being something like this for example:
- 96727a88f8f9687b0978f2326a0958eb.indian-remy-machine-weft-soft-fro-texture-4-oz
- 46111986d71173c1fd18077f12e71d9e.indian-remy-machine-weft-bodywave-texture-4-oz
- 2504371a156068516c1eb499877c3cce.indian-remy-machine-weft-kinky-straight-texture-4-oz
- 184771a9f3ea3bda364748cda80d54a5.indian-remy-machine-weft-silky-straight-texture-4-oz




Reply With Quote
Indeed this would be ideal functionality..
Of course.. I wasn't actually suggesting that exact make up for the file name..
