Hi All,
I'm currently developing my site to have ratings until 10 as you can see below:
http://www.epsonio.com/displayimage.php?album=toprated&cat=0&pos=2
As you can see I swapped out the star images (for now). How can I do the same on the "Top Rated" Page? Currently the images show up as follows:
http://www.epsonio.com/thumbnails.php?album=toprated&cat=0
Any help would be greatly appreciated!
-Simon
Look in include/functions.inc.php
case 'toprated': // Top rated pictures
and change the caption generating code as you like.
I too would like to get rid of the stars and add the rating in numbers. I was able to get rid of the image tag in the function page, and found the "current rating" code that I would like to insert. I found this code in displayimage page for "toprated"
$votes = $CURRENT_PIC_DATA['votes'] ? sprintf($lang_rate_pic['rating'], round($CURRENT_PIC_DATA['pic_rating'] / 2000, 3), $CURRENT_PIC_DATA['votes']) : $lang_rate_pic['no_votes'];
I just cannot figure out how to get that code into the Function code
$caption = "<span class=\"thumb_caption\">". .'<br />'.sprintf($lang_get_pic_data['n_votes'], $row['votes']).'</span>';
I tried just adding
sprintf($lang_rate_pic['rating'], round($CURRENT_PIC_DATA['pic_rating'] / 2000, 3)
into the function code, but got a parse error. I'm just not that good yet with PHP.
So am I even close or am I on another Island somewhere. :)
After a week of trying various combinations, I still cannot figure this out, can anyone help me with this one. Thanks.
for the toprated meta album:
find in functions.inc.php
$caption = "<span class=\"thumb_caption\">".'<img src="'.$prefix.'images/rating'.round($row['pic_rating']/2000).'.gif" align="absmiddle"/>'.'<br />'.sprintf($lang_get_pic_data['n_votes'], $row['votes']).'</span>';
replace with
$caption = "<span class=\"thumb_caption\"> Rating: ".round($row['pic_rating']/2000).'<br />'.sprintf($lang_get_pic_data['n_votes'], $row['votes']).'</span>';
Wow, thanks. That looked alot easier than the different one's I tried. Works great. Thanks.