Closed GoogleCodeExporter closed 9 years ago
Fixed. Thanks!
Original comment by tylerh...@gmail.com
on 24 May 2009 at 8:53
And I have made a better alternative:
[code]
/*get poster info*/
$p_url = "http://www.google.com/search?hl=en&q=themoviedb+" . urlencode($str) .
"&btnI=I%27m+Feeling+Lucky";
$p_html = $this->geturl($p_url);
$p_html = $this->geturl($this->match('|<a
href="(http://www.themoviedb.org/[\W\w\d\D\S]*)"|U', $p_html, 1));
$poster = $this->match('|<a href=".*" target="_blank" title=".*"><img
src="(/image/posters/.*)" width=".*" height=".*" /></a>|U', $p_html, 1);
if(!empty($poster)) $arr['poster'] = 'http://www.themoviedb.org'.$poster; [/code]
Maybe you could make it better. Because, when I uses google to search en use
"I'm
Feeling Luck", nothing happens when I search for something with
"themoviedb.org" in it :S
The posters from themoviedb are much bigger and do match better.
Not al the posters could be find on TMDb, so you still have to keep the one
from IMDb ;)
Original comment by k.schasf...@gmail.com
on 24 May 2009 at 10:34
Original issue reported on code.google.com by
k.schasf...@gmail.com
on 22 May 2009 at 9:09