gdrts_loop()->render()->thumbs()

gdrts_loop()->render()->thumbs($args = array(), $echo = true);

Description

Render the stars block. This method is used by Thumbs Rating method to display rating element stars. Depending on the rating method, $args array contains different parameters.

Parameters for $args

Thumbs Rating, Single Block

  • input_name: if set, the hidden input field with that name will be added.
  • input_value: if set to true, the font_color_empty field will be set to the current user previous rating for the item.
  • passive_mode: if set to true, click on the stars will not submit the rating. In that case, you need to handle rating submission.
  • allow_rating: if set to false, the rating will be disabled.
  • show_rating: allows values: rating (show actual rating), own (how own rating), hide (don’t show rating).
  • show_values: if set, size of the stars.
  • show_signs: if enabled, show + and signs for thumbs values.
  • suffix: associative array with ‘up’ and ‘down’ values to add after the rating thumbs.
  • labels: associative array with ‘up’ and ‘down’ labels. If not set, default labels from settings will be used.

If you need to modify all the styling properties (style type, name…), you should use the filter that runs before the template is actually loaded:

Thumbs Rating, Rating List

  • show_signs: if enabled, show + and signs for thumbs values.
  • suffix: associative array with ‘up’ and ‘down’ values to add after the rating thumbs.
  • labels: associative array with ‘up’ and ‘down’ labels. If not set, default labels from settings will be used.

If you need to modify all the styling properties (style type, name…), you should use the filter that runs before the template is actually loaded:

 

0
0
59
Rate this reference

You are not allowed to rate this post.

Comments

Leave a Reply