coppermine-gallery.com/forum

Support => cpg1.3.x Support => Older/other versions => cpg1.3 Themes/Skins/Templates => Topic started by: spanishben on October 02, 2004, 10:29:43 AM

Title: How can I remove/change alt information on thumbs page in eyeball?
Post by: spanishben on October 02, 2004, 10:29:43 AM
Hi,

I'm modifying the eyeball theme and want to change the alt information (filename, filesize, dimensions, date added etc.) that appears when you hover a thumbnail int he album thumbs page. I would either like to remove this info or change it to just display the image title instaed. I have seached theme.php, thumbnails.php and looked around this forum but can't find the answer or the code to fiddle with.
ANy help much appreciated.
Thanks,
Ben
Title: Re: How can I remove/change alt information on thumbs page in eyeball?
Post by: Casper on October 02, 2004, 11:33:01 AM
It is in functions.inc.php.

Find;

$pic_title =$lang_display_thumbnails['filename'].$row['filename']."\n".
                                $lang_display_thumbnails['filesize'].($row['filesize'] >> 10).$lang_byte_units[1]."\n".
                                $lang_display_thumbnails['dimensions'].$row['pwidth']."x".$row['pheight']."\n".
                                $lang_display_thumbnails['date_added'].localised_date($row['ctime'], $album_date_fmt);


To just display the file name, change it to;

$pic_title =$lang_display_thumbnails['filename'].$row['filename'];



NOTE;  You will have to do this twice, to do the same for the filmstrip as well.
Title: Re: How can I remove/change alt information on thumbs page in eyeball?
Post by: spanishben on October 02, 2004, 01:02:41 PM
Thanks very much for such a speedy response! I would never have found that!
Works perfectly.
I also discovered that by changing:

$pic_title =$lang_display_thumbnails['filename'].$row['filename'];

to

$pic_title =$lang_display_thumbnails['title'].$row['title'];

I get the actual picture title as the thumb alt instead, which is even better!

Thanks,
Ben

Title: Re: How can I remove/change alt information on thumbs page in eyeball?
Post by: spanishben on October 02, 2004, 09:55:50 PM
Sorry to come back again. I have also noticed that the thumbs for albums on the index page also have the filename as the alt text - e.g. "summer.jpg" (I have no categories, just albums directly on the index page). I would also like to change this so that it shows either the image title or nothing instead for this alt text. I have returned to functions.inc.php and tried replacing every instance of 'filename' for 'title', but can't get the alt text to change. Do you know which code I have to change for this?
Many thanks,
Ben
Title: Re: How can I remove/change alt information on thumbs page in eyeball?
Post by: Casper on October 03, 2004, 01:56:40 PM
Open index.php, find and change the 2 instances of;

alt=\"{$picture['filename']}\"

To;

alt=\"\"

And we have a 1 question per thread rule, please don't ask any more on this thread.
Title: Re: How can I remove/change alt information on thumbs page in eyeball?
Post by: spanishben on October 03, 2004, 07:23:08 PM
Thanks Casper, No more than one question on one thread from now on I promise!
Great software by the way, and support, really great.