Author Topic: Allmovie.com https  (Read 627 times)

0 Members and 1 Guest are viewing this topic.

Offline afrocuban

  • Power User
  • ****
  • Posts: 163
    • View Profile
Allmovie.com https
« on: October 10, 2017, 11:09:08 pm »
One more https transition. Allmovie.com script isn't possible to use anymore in PVD?

Kind regards.

Offline UtNut

  • User
  • ***
  • Posts: 62
    • View Profile
Re: Allmovie.com https
« Reply #1 on: October 11, 2017, 08:50:10 pm »

Same here, is there chance to work around https? Really love their comments.
1984 was NOT supposed to be an instruction manual

Offline Ivek23

  • Global Moderator
  • *****
  • Posts: 1877
    • View Profile
Re: Allmovie.com https
« Reply #2 on: October 12, 2017, 01:28:37 pm »
Tests Proxomitron. I think this would be an ideal solution for your problems. I also attach a default.cfg file that already has an added solution for the Allmovie.com https connection. How and what is described in topic:
Proxomitron - next https solution for PVD.

I did not test if it works, because at present I have many family responsibilities (my father is seriously ill) and there is no time for testing.

BTW:
I will know more about this somewhere around the first of November, how and what will happen in the next few months to the end of March of the following year.


default.cfg file is attach.
Ivek23
Win 7 32bit, 64bit   PVD v0.9.9.21


Offline afrocuban

  • Power User
  • ****
  • Posts: 163
    • View Profile
Re: Allmovie.com https
« Reply #3 on: October 14, 2017, 02:15:59 am »
Dear Ivek,

So sorry to hear about your father. Wish him well, please!

Thank you for your kind answer. Following your proxomitron guide I actually made it work for allmovie.com! The only strange thing is that it doesn't import AllMovie synopsis anymore.

Kind regards




Offline Ivek23

  • Global Moderator
  • *****
  • Posts: 1877
    • View Profile
Re: Allmovie.com https
« Reply #4 on: October 14, 2017, 08:23:44 am »
Dear Ivek,

So sorry to hear about your father. Wish him well, please!

Thanks.

Thank you for your kind answer. Following your proxomitron guide I actually made it work for allmovie.com! The only strange thing is that it doesn't import AllMovie synopsis anymore.

Allmovie.com script requires mass updates, which I can not do with the current situation. But I hope that as soon as possible,
so stay tuned for messages.

At the moment and quickly, I made corrections only in the ParseSearchResults procedure so that the script finds search results for a specific movie.

Code: [Select]
procedure ParseSearchResults(HTML : String);
var
curPos, endPos : Integer;
Title, Year, URL, director : String;
begin
//List of other site number where search page :
TabNumber := [''];

// curPos := Pos('<option value="movies" selected>', HTML);
// curPos := Pos('div class="results-section movies">', HTML);
curPos := Pos('<li class="movie">', HTML);
if curPos < 1 then
Exit;

LogMessage('Parsing search results...');

//curPos := PosFrom('<a href="http://www.allmovie.com/movie/', HTML, curPos);
curPos := PosFrom('<a href="https://www.allmovie.com/movie/', HTML, curPos);
while curPos > 0 do begin
endPos := PosFrom('">', HTML, curPos);
URL := Copy(HTML, curPos + 9, endPos - curPos - 9);
    URL     := StringReplace(URL, 'https://', 'http://', True, True, False);

curPos := PosFrom('">', HTML, curPos)+2;
endPos := PosFrom('</a>', HTML, curPos);
Title := Copy(HTML, curPos, endPos - curPos);

curPos := PosFrom('</a>', HTML, curPos)+4;
endPos := PosFrom('</div>', HTML, curPos);
Year := RemoveTags(Trim(Copy(HTML, curPos, endPos - curPos)), false);

// curPos := PosFrom('">', HTML, curPos)+2;
// endPos := PosFrom('</a></dd>', HTML, curPos);
// director := RemoveTags(Trim(Copy(HTML, curPos, endPos - curPos)), false);

AddSearchResult(Title+' '+Year, '', '', URL, '');
curPos := PosFrom('<a href="https://www.allmovie.com/movie/', HTML, curPos);

end;

AddSearchResult('', '', '', '', '');

//Get Name of movie to search :               
    MovieName := GetFieldValue(2);
    Explodestring(MovieName,TabMovieName,#32);
    MovieName := '';
    For I:=low(TabMovieName) to High(TabMovieName) do
    Begin
    MovieName := MovieName + #43 + TabMovieName[I];
MovieName := StringReplace(MovieName, '/', '-', true, false, true);
    end;
//Add Links to Page with other sites in TabNumber:
    For I := Low(TabNumber) to High(TabNumber) do
    Begin
URL := 'http://www.allmovie.com/search/movies/'+MovieName;
//AddSearchResult('Search in '+MovieName+' on AllMovie.com','Movie results','',URL,'');
AddSearchResult('Search in '+MovieName+' on AllMovie.com','','',URL,'');
  end;
 
end;
Ivek23
Win 7 32bit, 64bit   PVD v0.9.9.21


Offline Ivek23

  • Global Moderator
  • *****
  • Posts: 1877
    • View Profile
Re: Allmovie.com https
« Reply #5 on: October 15, 2017, 08:45:43 am »
AllMovie.com_new_HTTPS script
version 1.1.2.5

I managed to fix the AllMovie.com_new script, which now has a new name and is now called the AllMovie.com_new_HTTPS script.

There may be some other errors, but maybe they might be corrected later.

AllMovie.com_new_HTTPS script  is attached.




For all guests:

You can find a link to download the script in AllMovie.com_new_HTTPS Movie Links topic.
« Last Edit: October 15, 2017, 09:05:55 am by Ivek23 »
Ivek23
Win 7 32bit, 64bit   PVD v0.9.9.21


Offline afrocuban

  • Power User
  • ****
  • Posts: 163
    • View Profile
Re: Allmovie.com https
« Reply #6 on: October 17, 2017, 01:50:21 am »
Thank you, Ivek. The script works for me, but only with Proxomitron. Thank you.

Kind regards,

Offline VVV_Easy_Programing

  • User
  • ***
  • Posts: 96
    • View Profile
Re: Allmovie.com https
« Reply #7 on: October 17, 2017, 06:17:01 pm »
Best wishes for your father, Ivek.

Offline Ivek23

  • Global Moderator
  • *****
  • Posts: 1877
    • View Profile
Re: Allmovie.com https
« Reply #8 on: October 17, 2017, 06:31:58 pm »
Thank you, Ivek. The script works for me, but only with Proxomitron. Thank you.

Kind regards,

I am pleased. This was the only possible and quick solution to my current situation, which I could do for you all.
Ivek23
Win 7 32bit, 64bit   PVD v0.9.9.21


Offline Ivek23

  • Global Moderator
  • *****
  • Posts: 1877
    • View Profile
Re: Allmovie.com https
« Reply #9 on: October 17, 2017, 06:38:13 pm »
Best wishes for your father, Ivek.

Thanks. Fortunately, his situation is getting better.
Ivek23
Win 7 32bit, 64bit   PVD v0.9.9.21


Offline Ivek23

  • Global Moderator
  • *****
  • Posts: 1877
    • View Profile
Re: Allmovie.com https
« Reply #10 on: October 22, 2017, 12:40:33 pm »
AllMovie.com_new_HTTPS script
version 1.1.2.6

Repair some errors. So far it was possible to download information only for actors and director. From now on, there is also the possibility of downloading information for the writer, producer and composer.

New version of AllMovie.com_new_HTTPS script  is attached.




For all guests:

You can find a link to download the script in AllMovie.com_new_HTTPS Movie Links topic.
Ivek23
Win 7 32bit, 64bit   PVD v0.9.9.21


 

anything