Here is a beta version of Additional Image Titles. It doesn't have a readme yet, so here are the instructions:
Unzip on your pc, navigate to /includes/modules/ and change /your_template/ to the name of your custom template.
Open /includes/languages/english/extra_definitions/additional_image_titles.php and add defines for your additional image files, like this:
define ('ADDIMG_RINGS_RING23_01_JPG','Additional View #1');//title for /images/rings/ring23_01.jpg
define ('ADDIMG_HOE_SIDE_JPG','Side View');//title for /images/hoe_side.jpg
The code that does the work in /includes/modules/your_template/additional_images.php is quite simple:
PHP Code:
// additional image titles - gjh42 20090105
$badchars = array('/','.','-',' ');//not allowed in constant names
$add_const_name = 'ADDIMG_' . strtoupper(str_replace($badchars,'_',$file));
// uses file ext and subdir if any in constant name, e.g. ADDIMG_RINGS_RING23_01_JPG for /images/rings/ring23_01.jpg
// define constants in /includes/languages/english/extra_definitions/additional_image_titles.php
// if any other characters could be used in filename, add them to $badchars
$link = (defined($add_const_name))? $add_const_name . '<br />' . $link: $link;
// /additional image titles - gjh42 20090105
// List Box array generation:
It goes just before the list box array element is constructed.
Sure, you could use a db table to do this instead. If you want to do another version, go ahead:)