$49

Star Ratings

Documentation  •  Changelog

Documentation

Get rating cast by a specific user

Find out exactly what rating a specific user gave to a specific element...

craft.starRatings.userRating(userId, elementId [, key = null])
  • userId - ID of user who cast rating
  • elementId - ID of element being rated
  • key - (optional) For elements with multiple aspects

The same can be done via PHP...

// Craft 2
craft()->starRatings_query->userRating($userId, $elementId [, $key = null])

// Craft 3
StarRatings::$plugin->starRatings_query->userRating($userId, $elementId [, $key = null])