Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: Thumbnail rollover info..? Simple change..help!  (Read 2943 times)

0 Members and 1 Guest are viewing this topic.

jjkatrina

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Female
  • Posts: 22
    • K~A~T~R~I~N~A
Thumbnail rollover info..? Simple change..help!
« on: June 05, 2005, 07:23:52 am »

As requested I have look over forum and found this post:

http://forum.coppermine-gallery.net/index.php?topic=186.0

they tell the info about where in functions.php to change..but I am wanting to make it simpler and don't know how. All I want to do is have for all thumbnail on site when you roll over to simply say the Title of the image, not the filename, dimensions, when added, etc. How would I edit code to just make it say the title?

I am think you would edit this section:

 $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);

But admit I don't know much of php  :\'(

And it looked that there were two sections just like this so what may I do? Any help I thank you!!! (you have been very kind before in helping..thanks!  :-* )
« Last Edit: June 06, 2005, 09:12:22 pm by Nibbler »
Logged

jjkatrina

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Female
  • Posts: 22
    • K~A~T~R~I~N~A
Re: Thumbnail rollover info..? Simple change..help!
« Reply #1 on: June 05, 2005, 04:11:45 pm »

 ??? i am still need of help!
Logged

Nibbler

  • Guest
Re: Thumbnail rollover info..? Simple change..help!
« Reply #2 on: June 05, 2005, 04:14:11 pm »

Did you try

Code: [Select]
$pic_title = $row['title'];
?
Logged

jjkatrina

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Female
  • Posts: 22
    • K~A~T~R~I~N~A
Re: Thumbnail rollover info..? Simple change..help!
« Reply #3 on: June 05, 2005, 04:59:18 pm »

thank you for the help nibbler! I just replaced the 2 instances of : (in functions.inc.php)

Code: [Select]
$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);

with simply:

Code: [Select]
$pic_title = $row['title'];
and works fine on the main page for "Recent Uploaded" area when I moused over, but I have 2 other sections on my main page "Most Viewed" and "Random" and when I now moused over them - it shows nothing??! Why is this? (neither just title or old info) Is there more code I needed to edit differently?
Logged

Nibbler

  • Guest
Re: Thumbnail rollover info..? Simple change..help!
« Reply #4 on: June 05, 2005, 05:02:13 pm »

You may need to edit the db query to pull the title from the database, it's not requested for all meta album types. I'll post how to do this when I return tomorrow (unless someone else wishes to do so before then).
Logged

jjkatrina

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Female
  • Posts: 22
    • K~A~T~R~I~N~A
Re: Thumbnail rollover info..? Simple change..help!
« Reply #5 on: June 06, 2005, 02:58:47 am »

ok thank you! I will be checking up to see !  :D
Logged

Nibbler

  • Guest
Re: Thumbnail rollover info..? Simple change..help!
« Reply #6 on: June 06, 2005, 08:15:28 pm »

include/functions.inc.php

look for

Code: [Select]
case 'random':
and then look below that for

Code: [Select]
if($select_columns != '*') $select_columns .= ', aid';
now, add in title to that list

Code: [Select]
if($select_columns != '*') $select_columns .= ', aid, title ';
do a similar thing for meta albums that don't show the title by default.
Logged

jjkatrina

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Female
  • Posts: 22
    • K~A~T~R~I~N~A
Re: Thumbnail rollover info..? Simple change..help!
« Reply #7 on: June 06, 2005, 08:52:11 pm »

 :D

You are MOST helpfull..thank you. It fixed it and I updated for 'random' and 'topn' ..thank you again!!  :-*  :-*  :-*
Logged
Pages: [1]   Go Up
 

Page created in 0.018 seconds with 15 queries.