Change rating display for images. Change rating display for images.
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Change rating display for images.

Started by Bryce F, April 16, 2006, 11:31:07 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Bryce F

How would I go about doing this:
I want to change the way ratings are displayed on the per-image level to match the per-thumbnail style.  Instead of saying "rating: 3.67 (with 3 votes)," I'd like it to round() this value and display the corresponding star image.

In "include/functions.inc.php" there is a line:if($select_columns != '*') $select_columns .= ', title, caption,hits,owner_id,owner_name,pic_rating,votes';
followed soon by:if ($set_caption) build_caption($rowset, array('pic_rating'));
(I modified these lines based on thread: http://forum.coppermine-gallery.net/index.php?topic=27925.0)
Can I get the images to display in the same way (without the <br> between stars and number of votes)?

Thank you.

Bryce F

Addendum:
It would be cool to know specifically how this works so that I can add incremental .5 intermediate star values (and create corresponding new images for these).  Knowing how to apply this to thumbnail ratings and my proposed image rating would be nice.

Bryce F

Bump.  This was about to fall off of Page 1.
If nobody responds after this, I'll assume nobody knows.