WP Movie Ratings

WP Movie Ratings is a WordPress plugin perfect for movie fans who like to let the world know their opinion on what they’ve been watching. At its core is a bookmarklet, which combined with Internet Movie Database and a little bit of AJAX magic lets you rate movies with just one click. Also, there is no need to write the title of the movie as it is automatically fetched from imdb. Optionally, you can also write a short review for each movie. The output from this plugin is a list of recently watched movies, which you can put anywhere you want (it is a WordPress widget). Check out the live demo.

The published movie reviews are hReview compliant.

Download current version of the WP_Movie_Ratings wordpress plugin.

Latest stable version (for WordPress 2.8+): 1.8 (tar.gz, zip) (2019-10-13).

The current development version can be found at github.

Screenshots

Recently watched movies list:

WP Movie Ratings wordpress plugin in action (recently watched movies)

Bookmarklet in action (one click movie rating):

WP Movie Ratings wordpress plugin in action (Firefox bookmarklet)

Requirements

  • WordPress 2.8+
  • FTP, SSH or SCP access to your wordpress blog (so you can upload this plugin).

Installation

  1. Download the plugin.
  2. Extract the contents of the .tar.gz/.zip file into the WordPress plugins directory (usually wp-content/plugins). Alternatively you can upload them using ftp. You should have a new directory there called wp_movie_ratings (just along the akismet directory).
  3. Activate the plugin by going into your administration panel and selecting Plugins from the menu and clicking the Activate button for the WP Movie Ratings.
  4. Go to the Manage section in the administration panel and see the new Movies menu option there (you’ll find the bookmarklet there too). Rate at least one movie (using the bookmarklet or the administration page).
  5. Go to the settings section in the administration panel and under the Movies tab customize this plugin’s options.
  6. Customize your theme by adding a new Widget to its sidebar called “Movie Ratings”.
  7. Make a new page listing all your movie reviews by adding a new page in WordPress with this as its content: [[ wp_movie_ratings_page]].
  8. Go to your blog and see the movie ratings! :)

Upgrading

  1. Download the newest version of the plugin.
  2. Go to the Plugins section of the administration panel and deactivate the WP Movie Ratings plugin. Don’t worry as it will never ever delete any movie ratings.
  3. Go to the wp_movie_ratings plugins directory and delete all of the plugin files (should be wp-content/plugins/wp_movie_ratings). It will not delete any movie ratings (those are saved in the database). Be aware though, that if you’ve made any changes to the plugin, you might consider doing a backup.
  4. Extract the contents of the .tar.gz/.zip file into the wp_movie_ratings directory (wp-content/plugins/wp_movie_ratings).
  5. Go to the Plugins section of the administration panel and activate the WP Movie Ratings plugin (notice that higher version number of the plugin). The deactivation/activation cycle is required because of the new options that need to be written into the wordpress database (during activation).
  6. Enjoy life with the newest version of the WP Movie Ratings plugin!

FAQ

How can I have the ratings box displayed right after the first post?

Assuming you want to have movie ratings displayed on the front page of your blog, edit the index.php file. Find the line similar to this one:

<?php while (have_posts()) : the_post(); ?>

Change it so it looks like this:

<?php $first_post = true; ?>
<?php while (have_posts()) : the_post(); ?>

And then, inside the while loop find this line:

<?php endwhile; ?>

and make it look like this:

<?php
if ($first_post) wp_movie_ratings_show();
$first_post = false;
?>

<?php endwhile; ?>

And that should do it.

How can I create a separate page listing all of my movie reviews?

Create new WordPress page by selecting Write Page in the Write menu option of the administration panel and put this line as the page content:

[[ wp_movie_ratings_page]]

How to I make the imdb link open in a new window?

Open movie.class.php and change this line:

$o .= "<a class=\"url fn\" href=\"";

to

$o .= "<a class=\"url fn\" target=\"_blank\" href=\"";

What to do when the rating box is too wide?

Wrap the plugin function call in a fixed width <div>, like that:

<div style="width: 200px">
<?php wp_movie_ratings_show(); ?>
</div>

Your plugin is not working! All I get are (EmptyReference!) errors!

Stop using Adobe GoLive! as it is utter evil.

The bookmarklet is not working! Help!

Currently the bookmarklet works in Mozilla Firefox, Camino and WebKit. No IE, sorry.

Check if your blog’s home address is the same as your wordpress installation. If it is not (for instance when your website’s address is example.com and there sits your wordpress installation, but your blog is located at blog.example.com), then using this bookmarklet is not possible as that kind of AJAX calls are regarded as XSS and are blocked by Firefox (by default). You need to mess with your wordpress installation for it to work.

I’m using the Markdown plugin and I cannot create a movie ratings page!

Instead of writing:

[[ wp_movie_ratings_page]]

try

<!--wp_movie_ratings_page-->

and if that still does not work for you, wrap the call in a <p> tag, like this:

<p><!--wp_movie_ratings_page--></p>

or like this:

<p>[[ wp_movie_ratings_page]]</p>

How can I have the reviews shown when in page mode but hidden while in sidebar mode?

Go into settings in the administration panel and set all of the settings you want to have for the page mode. For the sidebar mode execute the following php code:

<?php wp_movie_ratings_show(6, array("sidebar_mode" => "yes", "include_review" => "no")); ?>

The first parameter of the wp_movie_ratings_show() function is the number of latest movie reviews to show. The second is the array of additional display options (all are optional). Here is the list of all the options you can set (hash array):

  • text_ratings – text ratings (like 5/10) instead of the stars,
  • include_review – include review with each movie rating,
  • expand_review – initially display expanded reviews when in page mode,
  • sidebar_mode – compact view for sidebar mode,
  • five_stars_ratings – display movie ratings using 5 stars instead of 10,
  • highlight – will highlight the stars of top rated movies,
  • page_mode – display all movie ratings on a separate page,
  • page_url – link to the movie reviews page,
  • char_limit – will cut any character in the title after this number,
  • only_not_rated – will select only not yet rated movies (‘yes’/’no’),
  • only_rated – will select only already rated movies (‘yes’/’no’),
  • order_by – default sort (valid only when used with combination of either ‘only_rated’ or ‘only_not_rated’) (‘title’/’rating’/’watched_on’),
  • order_direction – default sort direction (valid only when used with combination of either ‘only_rated’ or ‘only_not_rated’) (‘ASC’/’DESC’).

Other questions?

Just ask.

License

Released and available under the GNU General Public License (GPL) version 2 or later.

Known bugs

  • Bugs? What bugs?

TODO

v2.0 plans:

  • Convert movie ratings from separate database table to normal posts and assign custom tag to hide them from normal content (similarly to the sideblog plugin). Doing this will give us: integrated search for already rated movies, RSS feeds, comments under reviews, permalinks to each review.
  • Automatically fetch movie covers from amazon, fetch director, cast, rating, movie language from imdb (when adding a new review).
  • Automatic updates through the WordPress plugin administration panel.

Post v2.0 plans:

  • Use static methods of Movie class, like Movie::get_watched_movies_count() instead of what I’m doing currently (tested; works in PHP 4.4.x).
  • Different color schemes/images for different blog backgrounds (white/black/transparent) using different CSS selectable via panel option.
  • Dynamic graph chart showing the votes breakdown.
  • Automatic voting on imdb.
  • Amazon links ($$).
  • Bookmarklet working in Internet Explorer.
  • Implement vote history import from imdb.com (and somehow solve the watched_on problem as imdb doesn’t tell when the movie was rated).
  • Expand on the concept of this plugin being a general rating plugin, which will let you rate books and music too.
  • Implement multiple users ratings (for multi-author websites).
  • Automatically collect the movies you saw each month/week and post them on the blog.

Changelog

2015-11-19

  • full compatibility with WordPress 4.4+.
  • widgetization: added possiblity to display ‘Recent ratings’ in a widget
  • fetch original movie titles from IMDb (ie: use akas.imdb.com instead of just imdb.com) and display links to akas.imdb.com (instead of imdb.com)
  • fixed: make movies page pagination links XHTML standards compliant (& => &)
  • compatibility/deprecation fixes (some of them at least…)
  • release 1.7.

2010-10-14

  • full compatibility with WordPress 2.7.*, 2.8.*, 2.9.* and 3.0.*.
  • fixed: when ‘only_rated’ or ‘only_unrated’ option was used the ‘count’ argument the for wp_movie_ratings_show() function was ignored.
  • removed automatic pingerati.net pinging (pingerati.net is AWOL).
  • fixed: fetching movie title from IMDb (after IMDb has changed their website).
  • release 1.6.

2008-05-18

  • added option to add movies without rating them (only through the administration panel) (to create a list of owned just not yet seen dvds, for example).
  • added option to select all ‘only_rated’ or ‘only_not_rated’ movies using the wp_movie_ratings_show() function call.
  • char_limit option can now be passed as a parameter to the wp_movie_ratings_show() function call.
  • fixed problems making the movie reviews pages non XHTML compliant.
  • fixed error which prevented certain users from activating the plugin (the database table was not created).
  • fixed XHTML validation error in the bookmarklet.
  • release 1.5.

2006-11-18

  • fixed lots of rendering issues (problems in IE, Blue-k2 theme, Golden Gray theme, reviews not expanding, etc.).
  • completely rewritten encoding module, so now international characters as well as HTML should work correctly.
  • fix for Markdown markup – you can now use the alternate tag: <!--wp_movie_ratings_page--> to create a movie ratings page.
  • new feature: if no imdb link is given, the plugin will not look for the movie’s title on imdb. As a drawback, there can be now movies without imdb links (and without titles…).
  • new feature: ability to edit imdb links for already rated movies.
  • new feature: added pagination in page mode (so movie reviews can now span among several pages).
  • added option to disable pingerati.net pinging.
  • added option to highlight top rated movies.
  • added link from the recently rated movies list to the page with all movie ratings.
  • movies are now grouped together by month when sorting by view date in page mode.
  • added default movies sorting options for page mode.
  • added a new database field with optional link that is used instead of imdb.
  • added option to initially display expanded reviews in page mode.
  • added ability to edit movies directly from the displayed ratings list (in page mode too).
  • release 1.4.

For previous changes check out the changelog file within the plugin’s archive.

Similar plugins

594 thoughts on “WP Movie Ratings”

  1. hi,

    another feature request: a field in the settings where we can set the default view options. i mean, like time descending sorting.

  2. alper -> Not yet. I’d like to see it that way too (sorting by date by months/years), so there is a good chance that it will be like that (quite soon). There will be also an option to set the default sorting order when in page mode.

    Stadi -> The font change is ok. I’ve decided that the title should be displayed using the theme’s font, so any font change will be visible in my plugin. Now as for the reviews, I think that it’s not a K2 related problem, but some aggressive plugin that you’re using. In the source code of your blog I can see this: .description { display: block !important; (...) }. This line prevents the reviews to work correctly. Try to find what puts this line there and, if possible, remove it. Plus, you have reviews in the sidebar and in the body of the page, which makes the HTML invalid (and that creates some problems too). There should only be one movie reviews box per page.

    Jason C. -> It has something to do with your theme and IE (in Firefox it looks ok). When I go to “Resume” on your blog I have the same gap so it has nothing to do with my plugin.

  3. Hi Paul, Thanks so much for the plugin. I have been struggling with starred review for the last month with little to no success and your plugin came in and savd the day. So thanks!

    The small problem I’m having is when I try to include the last five movies revieved in a post my stars end up lining up vertically instead of horizontally. Do you know of a way to fix this? thanks in advance for all your help.

  4. hubs -> If your stars line up vertically it usually means that the movie reviews box is a part of an open <pre> tag. It’s a wordpress issue/feature – try closing the tag and see if it helps (looking at source code first to confirm this is sensible too).

  5. Hi! I’ve put the “.description { display: block !important; …” thing into the css, so that it doesn’t display the description of the blog in the header. It used to work in previous versions of K2 without “!important” but in the new version it doesn’t, that’s why I had to put it there.

    Is there a way to make the reviews in the sidebar appear only on the frontpage? I don’t like that they are there always, but two of them only appear in the movies page.

  6. stadi -> Now I know that it is a K2 related issue. One of the styles (k2blue) includes a very aggressive !important rule on the .description class, which leaves my hands tied as I cannot get around this issue. I’ll try to work on that, though.

    hubs -> Wait for the newest version and then tell me if it still displays the stars like that.

  7. etherea -> You don’t understand. The plugin is making http connection to imdb.com from the machine that your weblog is _hosted_, not from your local computer. This is what might be blocked as you’re the first user to report that.

  8. This is such a cool plugin! One tiny problem I’m having though is that when I try to post from the bookmarklet, it says, “Error: cannot add movie rating. Not logged in.” Errr, I am logged in. Why does it keep doing this? I’d love to use the bookmarklet because it’s ridiculously convenient (particularly since I spend half my off work internet time browsing IMdB like a dork). Thanks!

    Rachel

  9. Thanks for the great plugin :) I love it!

    I have a question though. Is it possible to delete the ‘Watched and reviewed on’ thing in the tooltip manually? Should I delete a line of code? I’m not that into php so I’m not sure if I can delete something or not. Thanks!

  10. Zeph -> This is a known problem which will be fixed in v1.4 (to be released quite soon).

    Rachel -> Hard to say. It works for me so I cannot trace the problem. Maybe try hitting F5 before clicking on any of the stars?

    Sanne -> Search for "# Movie title" text in the movie.class.php and delete the title attribute from the link few lines below.

  11. Great plugin.

    Just wondering if it takes long before you implement this:

    v2.0: Convert movie ratings from separate database table to normal posts and assign custom tag to hide them from normal content (similarly to the sideblog plugin). This way we get automatic RSS feeds, comments and permalinks to each movie review.

    I will use your plugin as soon as this is implemented, because if want my readers to give ratings also (im using postratings plugin), and i want to use that plugin with yours. Is it a easy way to do this so i can use the postratings plugin? Keep up the good work!

  12. Hi Paul,

    Love your plugin. However, I’m experiencing some problems. When I just installed everything worked fine. But for some reason it has stopped displaying the text of the movie ratings on my main index, even though my settings are set to display them.

    I have de-installed and installed and tried puting the code somewhere else in the page (just to see if it was somehow connected to its place in de the page), but nothing worked. Also, I changed all settings forth and back, but nothing worked.

    Any ideas? Thanks.

  13. Tom -> I’m afraid that it’s still a long way till that happens. But who knows… ;)

    Ivar -> That’s a known problem related to your theme. Kubrick’s CSS overwrites rules set in wp_movie_ratings plugin. This issue has been resolved, so no need to worry. You’ll have your reviews as soon as I finally release v1.4 (which is ready to be released).

  14. Good – just checked your TODO. Boy you are ambitious – plans all the way to ver 3!

    I like it as it is – so do not hesitate for my sake. Haha.

  15. Hello, i love this plugin!

    but i had a problem… i use markdown… the [[***]] markup didnt work, so i had to edit the php…

    maybe if for next rls you change it to

    would be nice… sory for my bad english

  16. rolle -> Try creating a new page and enter [[wp_movie_ratings_page]] tag there. Alternatively you may try this in your template: <?php wp_movie_ratings_show(9999, array("page_mode" => "yes")); ?> And like, uhm, wait few days for v1.4 too ;)

  17. Thanks Paul. I have to say that your plugin is more than brilliant. I admire your work a lot and I can’t wait till version five :D Sounds too good already. Keep in touch!

  18. Is it possible to show little statics about watched movies, for example how many movies watched in years 2000-2006 for example? that would be nice!

  19. Rolle -> you have your statistics in the administration panel. At one point I made it so that you could include them in the page view as well but run into some problems, so it got kind of abandoned. But it’s still possible using the wp_movie_ratings_show_statistics() function. You just need to look into the code.

    Caius -> thanks for the info. I’ll update the page.

  20. Mike -> Yes, there is a way to do that but you need v1.4 which was about to be released more than a week ago but you know, life got in the way. I’ll release it hopefully in the not too distant future. It should also fix those CSS problems you’re having.

  21. Great plugin Paul. Just what I’ve been looking for. Easy to install and setup. One question for you. I don’t use this in my sidebar at all, only as a page. I plan to list a whole lot of movies that we’ve seen over the years. Is there a way to limit how many movies are listed on one page, before it starts another page. Say I only wanted to show 100 movies per page, is that possible now or maybe possible in a future release? Again, great job, keep up the good work.

  22. Anybody who wants to integrate their wp_movie_rating stats with Lester Chans wp_stats, here’s how you do it! I’m using wp_stats version 2.0.5, but I guess it should work the same with previous versions, but it hasn’t been tested with previous versions. Enjoy!

    Open up stats.php, find:Code:
    if($stats_display[‘recent_posts’] == 1 || $stats_display[‘recent_commtents’] == 1 || $stats_display[‘commented_post’] == 1 || $stats_display[’emailed_most’] == 1 || $stats_display[‘rated_highest’] == 1 || $stats_display[‘rated_most’] == 1 || $stats_display[‘viewed_most’] == 1) {

    Add above it:Code:
    if(function_exists(‘wp_movie_ratings_get_statistics’)) {
    $temp_stats .= ‘‘.__(‘WP-MovieRatings’).’‘.”\n”;
    $temp_stats .= wp_movie_ratings_get_statistics();
    }

  23. Paul,
    Just wondering, when do you suspect that v1.4 will be availble? Also, do you want any beta testers? If so, I’m really interested…I have to get my movie page, paged (so it isn’t so long) or it’s going to drive me crazy..lol

Comments are closed.