tags:

views:

1263

answers:

5

movie id tt0438097 can be found at http://www.imdb.com/title/tt0438097/

What's the url for its poster image?

+5  A: 

The URL is a random string as far as I can tell.

It can still be easily retrieved. It is the only img inside the anchor named poster.

So, if you are reading the source, simply search for <a name="poster" and it will be the text following the first src=" from there.

However, you will need to keep the screen scraping code updated because that will probably change.


You should also be aware that the images are copyrighted, so be careful to only use the image under a good "fair use" rationale.

Vincent McNabb
+7  A: 

As I'm sure you know, the actual url for that image is

http://ia.media-imdb.com/images/M/MV5BMTI0MDcxMzE3OF5BMl5BanBnXkFtZTcwODc3OTYzMQ@@._V1._SX100_SY133_.jpg

You're going to be hard pressed to figure out how it's generated though and they don't seem to have a publicly available API.

Screenscraping is probably your best bet.

The picture seems to generally be inside a div with class=photo and the name of the a tag is poster.

The image itself is just inside the a tag.

Mark Biek
A: 

Those poster images don't appear to have any correlation to the title page, so you'll have to retrieve the title page first, and then retrieve the img element for the page. The good news is that the img tag is wrapped in an a tag with name="poster". You didn't say what kind of tools you are using, but this basically a screen scraping operation.

Chris Noe
The images don't have any correlation to any page simply because one image could be assigned to multiple pages (movies, actors, etc.) and vice verse.
Nouveau
A: 

Be aware tough, that the terms of service explicitly forbid screenscraping. You can download the IMDB database as a set of text files, but as I understand it, the IMDB movie ID is nowhere to be found in these text files.

Peter V. Mørch