English > Talk

Alternative

<< < (6/15) > >>

Ivek23:

--- Quote from: afrocuban on May 20, 2018, 10:10:18 pm ---Dear Easy, thanks for your work! It is truly and sincerely appreciated. Although still no luck for me with IMDB and FA scripts. Still same errors about no internet connection and started of course via portable.bat.
--- End quote ---

If you've made a test with Proxomitron or proxy on, then it really does not work.

For me:
Namely, with the movieAffinity [ES] script, it works smoothly on the Win 7 Ultimate 32 bit, while the Imdb script alternately (depending on the movie title) works or does not work. The system works without a proxy method, which I do not even use, except Proxomitron, which, however, is not switched on when I test PVD MOD.


--- Quote from: afrocuban on May 20, 2018, 10:10:18 pm ---Dear Ivek, it doesn+t work neither with your attached scripts.
--- End quote ---

Attached Imdb scripts have been added (with a view to possible testing) primarily for the VVV_Easy_Programing member to see what information would be needed to be included in the script and parts of the code for help at writing the Imdb script.

Ivek23:

--- Quote from: VVV_Easy_Programing on May 15, 2018, 09:08:24 pm ---The Alfa 2 versión:
--- End quote ---

The good news for this version of Imdb script is that the download code for Imdb awards is right,
which I have been waiting for a long time (I did not find the right way to code it myself) and I have now come to see her, that I can now add it to the usual Imdb Movie (awards) script.

Imdb Movie (awards) script is ready and will soon be added to the forum.

I am extremely grateful for this solution VVV_Easy_Programing member and in doing so I would like to thank for the extraordinary efforts, which he invested in writing the code for downloading Imdb awards.

VVV_Easy_Programing:
I see that you can use a big parts of the HTTPS the scripts for your Proxomitron solution: I will change my scripts schema and i'm going to programate in funtions that you can use easily.

BTW see the post 'Script editing with NotePad++':
http://www.videodb.info/forum_en/index.php/topic,4133.msg20546.html#msg20546

beacuse the highlight and the folding is a very good help for the script programmer.
Note: If you can pin in the forum the NotePad post I think it would be good for all people.

VVV_Easy_Programing:
The Alfa 3 version:
http://vvveasy.altervista.org/wp-content/uploads/2018/05/PersonalVideoDB_MOD-V.Alfa_.3.zip

A lot of improvements and corrections of yours detected problems

Remember run with "portable.bat" (that is with the debug mode set in this test version).
If you have problems, please post the two files:
               PersonalVideoDB\log.txt   and   PersonalVideoDB\Scripts\PVdBDownPage.log

Now we are capable of change the script parameters, so I recomend see first the new Script "**** Scripts Configuration ****" (doesn't affect to database)
----------------------------------------------------------------------------------------------------------------
Important: This is a alfa version (even it not arrives beta level). Please is only for test, not mix your personal Database with this version. You may unzip in your desktop and run only in portable mode (portable.bat) without internet proxi.
----------------------------------------------------------------------------------------------------------------
Ivek23: I rewrite the IMDB script for easy Proxomitron adaptation (In the place of call function Download page, you may use the traditional script modes for make PVD download every page in the same script).
Ivek23: Show the posters in SearchList is now a script parameter, use new Script "**** Scripts Configuration ****" to switch. I didn't see the advantage of use 'http://www.imdb.com/find?q=' in the place of 'https://www.imdb.com/search/title?title=' because I get a lot of "false" results. We can analyse this later.
Afrocuban: The FilmAffinity in english is not ready but now you have a script parameter that allows set FilmAffinity rating (or TheMovieDB rating) as user rating, so you have the possibility of three ratings: IMDB, user and other ratting. Three customs fields are setting for save the  votes).

Ivek23:
Test for PersonalVideoDB_MOD-V.Alfa_.3

FilmAffinity_[ES][HTTPS] and TheMovieDB_[EN][API] script it works ok.

IMDB_ [EN] [HTTPS] script as it is now, very rare cases that it works at all, most often a window appears asking for confirmation, restarting or turning off PVD. However, once I removed all MPAA, AKA, CAST and AWARDS data transfer pages, the situation has been significantly corrected, but there is still a window with the request to confirm, restart or turn off the PVD. There is no download of information for Release Date, Budget, Cumulative Worldwide Gross, Runtime. I add a piece of code before I download the information and after it transfers the information.

Release Date  before
--- Code: ---    //Get ~rdate~ in contry provider local IP geolocation. See: http://sobizarre-en.blogspot.fr/2014/12/how-to-easily-defeat-imdb-geolocation.html
    curPos:=Pos('<h4 class="inline">Release Date:</h4>',HTML);                                      //WEB_SPECIFIC
    If 0<curPos Then Begin       
       ItemValue:=TextBetWeen(HTML,'<h4 class="inline">Release Date:</h4>','(',false,curPos);  //Strings which opens/closes the data. WEB_SPECIFIC
       AddFieldValueXML('rdate',ItemValue);
       LogMessage('      Get results Release Date:'+ItemValue+'||');
    End;
--- End code ---
Release Date  after
--- Code: ---    //Get ~origlang~ (several values in a comma separated list)
    curPos:=Pos('<h4 class="inline">Language:</h4>',HTML);                                      //WEB_SPECIFIC.
    if 0<curPos then begin       
       ItemValue:=TextBetWeen(HTML,'<h4 class="inline">Language:</h4>','</div>',false,curPos);  //Strings which opens/closes the data. WEB_SPECIFIC
       //ItemValue:=StringReplace(ItemValue,'|',',',True,True,False);                           //Change the separator to comma
       ItemValue:=StringReplace(ItemValue, '            |        ', ', ', true, false, true);
       AddFieldValueXML('origlang',ItemValue);
       LogMessage('      Get results Language:'+ItemValue+'||');
    end;       
    //Get ~rdate~ in contry provider local IP geolocation. See: http://sobizarre-en.blogspot.fr/2014/12/how-to-easily-defeat-imdb-geolocation.html
    curPos:=Pos('<h4 class="inline">Release Date:</h4>',HTML);                                      //WEB_SPECIFIC
    If 0<curPos Then Begin       
       ItemValue:=TextBetWeen(HTML,'<h4 class="inline">Release Date:</h4>','(',false,curPos);  //Strings which opens/closes the data. WEB_SPECIFIC
            ItemValue:=StringReplace(ItemValue,'January','1',true,true,true);
            ItemValue:=StringReplace(ItemValue,'February','2',true,true,true);
            ItemValue:=StringReplace(ItemValue,'March','3',true,true,true);
            ItemValue:=StringReplace(ItemValue,'April','4',true,true,true);
            ItemValue:=StringReplace(ItemValue,'May','5',true,true,true);
            ItemValue:=StringReplace(ItemValue,'June','6',true,true,true);
            ItemValue:=StringReplace(ItemValue,'July','7',true,true,true);
            ItemValue:=StringReplace(ItemValue,'August','8',true,true,true);
            ItemValue:=StringReplace(ItemValue,'September','9',true,true,true);
            ItemValue:=StringReplace(ItemValue,' October ',' 10 ',true,true,true);
            ItemValue:=StringReplace(ItemValue,' November ',' 11 ',true,true,true);
            ItemValue:=StringReplace(ItemValue,' December ',' 12 ',true,true,true);
            //ItemValue:=StringReplace(ItemValue, ' ', '.', true, false, true);
            ItemValue:=StringReplace(ItemValue, ' ', #46, true, false, true);       
       AddFieldValueXML('rdate',ItemValue);
       AddCustomFieldValueByName('Imdb Release Date',ItemValue);
       LogMessage('      Get results Release Date:'+ItemValue+'||');
    End;
--- End code ---

Runtime  before
--- Code: ---    //Get ~lenght~ (User option GET_LENGTH)
    If GET_LENGTH Then Begin
       curPos:=Pos('<h4 class="inline">Runtime:</h4>',HTML);                                      //WEB_SPECIFIC.
       If 0<curPos Then Begin 
          ItemValue:=TextBetWeen(HTML,'<time itemprop="duration" datetime="PT','M">',false,curPos);  //Strings which opens/closes the data. WEB_SPECIFIC
          AddFieldValueXML('lenght',ItemValue);
          LogMessage('      Get result lenght:'+ItemValue+'||');
       End;
    End;
--- End code ---
Runtime  after
--- Code: ---    //Get ~lenght~ (User option GET_LENGTH)
    If GET_LENGTH Then Begin
       curPos:=Pos('<h4 class="inline">Runtime:</h4>',HTML);                                      //WEB_SPECIFIC.
       If 0<curPos Then Begin 
          ItemValue:=TextBetWeen(HTML,'<time itemprop="duration" datetime="PT','M">',false,curPos);  //Strings which opens/closes the data. WEB_SPECIFIC
          AddFieldValueXML('lenght',IntToStr(StrToInt(ItemValue)*60));
          LogMessage('      Get result lenght:'+ItemValue+'||');
       End;
    End;
--- End code ---

I have a suggestion to first edit the IMDB_ [EN] [HTTPS] script to download information from the basic IMDB movie pages, but then the rest of the above pages, because this is at least in my estimation the main reason that the complete IMDB_ [EN ] [HTTPS] script, often causes a window to appear with a request to confirm, restart or turn off PVD.

There was also an error in downloading the URL of the address, shown in the code below.

--- Quote ---//Parse return of 'SearchList Movie URL'-----------------------------------------------------------------------
    If (Mode=smSearchList) Then Begin       //The user have choose the link.
        LogMessage('  ParsePage mode smSearchList. Getting DownloadURL from the return of smSearchList');
      DownloadURL:=StringReplace(URL,CHEAT_PREFIX_URL,'',True,False,False);   //Eliminate the CHEAT_PREFIX_URL for get the true movie link
        DownloadURL:=StringReplace(DownloadURL,'http','https',True,True,False); //The direct url needed (no https redirection)
        DownloadURL:=StringReplace(DownloadURL,'httpss','https',True,True,False); //The direct url needed (no https redirection)        
        LogMessage('     Global Var-DownloadURL|'+DownloadURL+'|');
        Mode:=smNormal;
        Result:=prDownload;  //But not exit needed for download the page because is HTTPS
        LogMessage('     With the good movie URL it demand download the movie page');
    End;
--- End quote ---

When I know more, I will also explain this as I do now.
 

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version