I need to add star ratings to one of my custom post types. At first I coded them myself but when the rating challenge came along i thought about using a plugin instead, so I used easy post types.
I’ve tried a couple star rating plugins and none of them seem to work. For example, with WP-PostRatings, I used the next code in my single-customposttype.php:
<?php if(function_exists('the_ratings')) { the_ratings(); } ?>
The image shows, but clicking does nothing. The same thing happens with other plugins. Star Ratins only says “an error ocurred” but no other debug info is displayed.
So I don’t know if you could recommend alternate plugins or any alternate method to add the star rating feature for my custom post type, because can’t get it work as it is.
For any rating functionality I always turn to GD Star Rating by Milan Petrovic.
This plugin can do SO many things, including thumb rating, rating of comments, multiple ratings, etc. It can also handle Rich Snippets (for getting your star ratings shown in Google SERPs), caching mechanisms, etc..
In short, it can do a lot, and I generally use it because of its flexibility and capabilities.
You might need to change the code depending on your site, but here is how I have implemented it on one of my sites (in ‘single.php’ template file):
Warning: You will want to familiarize yourself with the settings of the plugin and read up on the documentation, but it will be time well spent.