I didn't like having to define a constant for each additional image (and neither do my clients), so here is another way based on the image filename:
-
Create a sub-folder for the particular product in the images folder, mine is called coasters.
-
Upload the main image via control panel and put it in the product folder you created. My file is coaster.jpg
-
Upload the other images into the same folder and name them based on the attributes:
coaster_Aqua.jpg
coaster_Red.jpg
coaster_Blue.jpg
coaster_Magenta.jpg
Modify the code in additional_images.php around line 100. This just extracts the name out of the file. I'm sure there is a less stupid way to code this, but here you go:
$imagename = (explode("_",$file));
$imagename = $imagename[1];
$imagename = (explode(".",$imagename));
$imagename = $imagename[0];
$img_thumb = zen_image($products_image_directory . $file, addslashes($products_name), SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '<br />' . $imagename;
Thats it. Now as you add additional images just name them according to the convention and you should be good to go. I haven't really tested this much so if it screws something up I apologize.
JW