• Page 1 of 1
  • 1
Entry Rating in the informer
IoCiScommetto
Posts: 42
Reputation: 0

Message # 1 | 8:48 PM
I would like to add the entry rating feature (the five stars) into an informer.

I would like to get an informer that shows the entry name and below the possibility to rate it, without entering directly in the news.

Is this possible in some way?

I've tried to add the code

<?if($RATING$)?><div style="float:right"><?$RSTARS$('12','/.s/img/stars/3/12.png','1','float')?></div><?endif?>

but it doesn't work, it shows nothing.

Thank you for your help!

My site about betting: http://scommesse.ucoz.com
Paradox
Old Guard
Posts: 3284
Reputation: 145

Message # 2 | 2:08 PM
Please refer to Sunny's post below. -->
Jack of all trades in development, design, strategy.
Working as a Support Engineer.
Been here for 13 years and counting.
IoCiScommetto
Posts: 42
Reputation: 0

Message # 3 | 9:54 PM
Thank you!
And eventually would be possible to show just the actual rate (number of stars).
And then you have to enter in the news to rate it.

My site about betting: http://scommesse.ucoz.com
Sunny
Posts: 9296
Reputation: 456

Message # 4 | 3:37 PM
IoCiScommetto, it is possible with the help of the following codes: $RATING$ , $RATED$ (all available codes are displayed under an informer template)
I'm not active on the forum anymore. Please contact other forum staff.
IoCiScommetto
Posts: 42
Reputation: 0

Message # 5 | 9:39 AM
Thank you! I am able to display the number of stars, but not the stars themselves.. Which code should I use?
My site about betting: http://scommesse.ucoz.com
Sunny
Posts: 9296
Reputation: 456

Message # 6 | 12:17 PM
IoCiScommetto, use this code in the informer template:

Code
<ul title="Rating: $RATING$/$RATED$" class="u-star-rating">  
<li style="width:<?int($RATING$*20)?>%;" class="u-current-rating"></li>  
</ul>


And add also the styles:

Code
<style type="text/css">  
.u-star-rating{list-style:none;margin:0px;padding:0px;width:60px;height:12px;position:relative;background: url('/.s/img/stars/3/12.png') top left repeat-x;}  
.u-star-rating li{padding:0px;margin:0px;float:left;outline:none;}  
.u-star-rating li.u-current-rating{top:0;left:0;background: url('/.s/img/stars/3/12.png') left bottom;position: absolute;height:12px;line-height:12px;display:block;text-indent:-9000px;z-index:1;}  
</style>

I'm not active on the forum anymore. Please contact other forum staff.
IoCiScommetto
Posts: 42
Reputation: 0

Message # 7 | 12:40 PM
Thank you!!!
One last question, where should I add the styles?
In the Informer?

My site about betting: http://scommesse.ucoz.com
Sunny
Posts: 9296
Reputation: 456

Message # 8 | 1:28 PM
IoCiScommetto, yes, into the informer template.
I'm not active on the forum anymore. Please contact other forum staff.
IoCiScommetto
Posts: 42
Reputation: 0

Message # 9 | 1:40 PM
I've add both but actually it doesn't work

here is the page http://scommesse.ucoz.com/index/temp/0-126

instead of the stars it displays a black dot...

I've added the two codes one after the other

My site about betting: http://scommesse.ucoz.com
Sunny
Posts: 9296
Reputation: 456

Message # 10 | 2:04 PM
IoCiScommetto, sorry, there were some errors in the code. I've edited the codes above and tested them, they are correct now smile
I'm not active on the forum anymore. Please contact other forum staff.
IoCiScommetto
Posts: 42
Reputation: 0

Message # 11 | 5:58 PM
It works!
Thank you!

My site about betting: http://scommesse.ucoz.com
  • Page 1 of 1
  • 1
Search: