[SNIPPET] IMDb Rating
Posted: 13 Oct 2012, 14:18
The default {rating} binding is based on TheMovieDB data. If you need IMDb ratings there is 2 options:
1. The built-in {imdb.rating} binding that is using data from this webservice: http://www.deanclatworthy.com/imdb/
2. If they above doesn't work you can try scraping the imdb rating directly from the webpage like this:
1. The built-in {imdb.rating} binding that is using data from this webservice: http://www.deanclatworthy.com/imdb/
Code: Select all
{imdb.rating}
Code: Select all
{new URL("http://www.imdb.com/title/tt$imdbid").getText(requestProperties:['User-Agent':'Mozilla']).match(/(\d[.]\d)\/10/, 1)}