Yes, I seemed to find one response that sounds close to what I need :
************* Start of Paste **************
Figured out a way to display EXIF dates below thumbs.
" Reply #2 on: December 01, 2004, 12:52:21 PM "
--------------------------------------------------------------------------------
I came up with a solution that works for me, and so I'll present it as an option for the many seeking to display the EXIF date below the thumbnail.
I have the "Sort by EXIF" mod applied, and it works great. I noticed that when you run the mod, it extracts the EXIF date to the variable $pdate, and proceeds to write it to the database for each photo's "ptime". I noticed that it also converts this date to a human-readable format to display as text on the "results" page that you see after running the function. That variable is called $newdate.
Well, showing the date below the thumbnails was more important to me than showing a title (I don't use the title field at present anyway). So I just altered the script to write the date to the 'title' field.
In util.php:
After:
Code:
$query = "UPDATE $picturetbl SET ptime='$pdate' WHERE pid='$pid' ";
MYSQL_QUERY($query);I added:
Code:
$query = "UPDATE $picturetbl SET title='$newdate' WHERE pid='$pid' ";
MYSQL_QUERY($query);
A few lines above that, it defines the date format for $newdate. I altered this a little bit to be what I wanted:
Code:
$newdate = date('D, M jS Y \&\n\b\s\p\; g:i a', $pdate);
I have attached a screenshot crop of how it looks now. Works great if you value the date display over photos having a user-defined title. Hopefully someday a feature will be implemented into CPG so that a date display and title display could co-exist, but for now this is how I'm getting by.
*************** End of Paste *************
However, I do not want to lose the titles, which I have so painstakingly typed in as i uploaded each picture. I would rather just replace the UPLOAD date in the database, and therefore just cause it to display the new date ( the date from the EXIF info of each picture ) under the thumbnail. So, what should I change in this code here as suggested by this gentleman in his post ? And do I just edit util.php on my server in the crpmine directory ? and after that how do I make it run ? There is no option in Admin Tools to run util.php ( Isearched the forum for that already. Guess everyone but me knows how to run util.php !
Sorry, but I do not have that much experience in PHP.
Viji Rajasundram
www.sundram.org