Page 1 of 1

IMDB - improve search precision

Posted: 2015-04-10 12:59:09
by rs232
Two questions:

1) How do I go modifying the IMDB script to add the year (since it's available in the Year field) just after after the title?

e.g.

Avatar
=
Avatar 2009

2) Can the batch mode be modified to save and proceed automatically to the next record if 1 and only 1 result is found, but stopping and prompting to select the correct title in case of multiple results found?

Thanks!

Posted: 2015-04-10 14:36:35
by antp
1. Add the year where? Into the "original title" field?

2. If there is only one result found the script could skipt the prompt for selecting it indeed, that's just some tweaking to do in the script

Posted: 2015-04-10 15:38:57
by rs232
In the pop up gui when prompted to specify the title.

e.g. let's say I have Avatar in the title I select IMDB, it will open a pop up with Avatar in it.

I was wondering if it's possible to have "Avatar 2009" filled in automatically when opening the pop up

Posted: 2015-04-10 20:34:27
by antp
So you mean when updating movie info, when title & year were already filled?

Near the bottom of the script there is a line:

Code: Select all

      if not Input('IMDB Import', 'Enter the title or the IMDB URL of the movie:', MovieName) then
change it to

Code: Select all

      if not Input('IMDB Import', 'Enter the title or the IMDB URL of the movie:', MovieName + ' ' + GetField(fieldYear)) then
and it should work

Posted: 2015-04-11 06:52:44
by rs232
Thanks for that! i have actually worked out this version of mine:

if MovieYear = '' then
MovieYear := GetField(fieldYear);
MovieName := MovieName + ' ' + '(' + MovieYear + ')';
if GetOption('BatchMode') = 0 then
begin
if not Input('IMDB Import', 'Enter the title or the IMDB URL of the movie:', MovieName) then
Exit;
end

I did add the rounded brackets as after few tests I figured out that IMDB treat the content as a date.

e.g.

Search for (in order):

phoenix
phoenix 2014
phoenix (2014)

and spot the differences.

If I can add something here. Can we have an option into the IMDB script that consider/ignore "short movies" and "series"?

Posted: 2015-04-11 10:57:44
by rs232
Answering my own last point:

Using:

PopularTitleSearchURL = 'http://www.imdb.com/find?s=tt&ttype=ft&q=';

Will look for movies only.

The next evolution would be: do look for Movies first, if not found attempt "TV Movie", but I guess this would need substantial rewriting (may be not?)

Posted: 2015-04-11 15:14:39
by antp
rs232 wrote: if MovieYear = '' then
MovieYear := GetField(fieldYear);
That won't work correctly if you run the script on more than one movie.
There is no reason to test the value of MovieYear, you can overwrite it each time.