Personal Video Database

English => Development => Scripts and Templates => Topic started by: Ivek23 on April 07, 2012, 05:31:12 pm

Title: AllMovie.com_new movie script
Post by: Ivek23 on April 07, 2012, 05:31:12 pm
As you may have noticed, has again emerged and revived AllMovie.com web page (http://www.allmovie.com), but with a new and similar forms as it already has it AllRovi web site. (http://www.allrovi.com/)
There is now a new script, which is called AllMovie.com_new script, which is based on AllRovi movie script (http://www.videodb.info/forum_en/index.php/topic,2487.0.html), adapted to transfer data info with AllMovie.com web page. (http://www.allmovie.com) Describes the details are the same as in the first post in the AllRovi movie script. (http://www.videodb.info/forum_en/index.php/topic,2487.0.html)

There is now AllMovie.com_new movie script to test and that do have any additional adjustments (Indeed, the deficiencies for which the necessary corrections, but believes this does not manage to fix).

This is a change from the AllRovi movie script : (http://www.videodb.info/forum_en/index.php/topic,2487.0.html)

Removed was a ParseDVDreleases, remained a url link to AllMovie Releases tab.
Removed was Characteristics and Themes, because it is now united in Characteristics according to the subcategory which are listed below, with the exception Themes links.


Added to the new:




This script has now been released and is available via the program's auto-update system. Run Help > Check for updates and choose AllMovie.com_new from the list.
Title: Re: AllMovie.com - new movie script
Post by: rick.ca on April 07, 2012, 10:09:19 pm
While the style of the site is a little different, and some features are new, the data appears to be identical. Have you found any differences? Is there any data AllMovie has that AllRovi does not?

In any case, the script may serve as a useful backup to the AllRovi script. Thanks for your efforts.
Title: Re: AllMovie.com - new movie script
Post by: Ivek23 on April 08, 2012, 06:03:54 am
Have you found any differences? Is there any data AllMovie has that AllRovi does not?

Yes, small in user rating. In AllMovie showing the number of users who have given their votes for the rating, while this is not visible in AllRovi.

An example of movie: 10 Things I Hate About You (1999)

http://www.allmovie.com/movie/10-things-i-hate-about-you-v177526/
http://www.allrovi.com/movies/movie/10-things-i-hate-about-you-v177526

AMG ID is not visible in AllMovie.

BTW: Transferred only posters with . jpg extension.

In any case, the script may serve as a useful backup to the AllRovi script. Thanks for you efforts.

Thanks, rick.
Title: Re: AllMovie.com - new movie script
Post by: Ivek23 on April 18, 2012, 06:04:49 am
Have you found any differences? Is there any data AllMovie has that AllRovi does not?

Yes, small in user rating. In AllMovie showing the number of users who have given their votes for the rating, while this is not visible in AllRovi.

However, the this (user rating) can not be transferred, the same as with AllRovi, because the source code is not part of this information.
Title: Re: AllMovie.com - new movie script
Post by: Ivek23 on April 21, 2012, 05:30:56 pm
Good feature of this script is, that it works on old AllMovie URLs. Script of each of these URLs, not deleted or overwritten, so they remain in the URLs box. They also in the URL field added to the new URLs, which script transferred from the AllMovie new web site.
Title: Re: AllMovie.com - new movie script
Post by: Ivek23 on June 15, 2012, 05:33:14 am
Have you found any differences? Is there any data AllMovie has that AllRovi does not?

When movies are differences as already described here. (http://www.videodb.info/forum_en/index.php/topic,3154.msg15354.html#msg15354)

More visible difference is in the web pages of people.

For example:
Elvis Presley for AllRovi web page: http://www.allrovi.com/name/elvis-presley-mn0000180228
Elvis Presley for AllMovie web page: http://www.allmovie.com/artist/elvis-presley-p107032

There are many such cases as listed. Certain changes or differences are visible in the Info data for all the people, which are stored in the database.
Title: Re: AllMovie.com - new movie script
Post by: rick.ca on June 15, 2012, 07:28:38 am
Quote
More visible difference is in the web pages of people.

My question pertained to data not visible differences, and movies not people. The Rovi site includes music data, but there doesn't appear to be any additional movie data—on movie or people pages.

Now what would be really useful is an AllMusic script for album information. The redesign of that site has hopelessly broken the script I was using (a mod of the original AllMovie script). I'm not looking forward to rewriting that. :'(
Title: Re: AllMovie.com - new movie script
Post by: Ivek23 on June 15, 2012, 05:14:34 pm
Now what would be really useful is an AllMusic script for album information. The redesign of that site has hopelessly broken the script I was using (a mod of the original AllMovie script). I'm not looking forward to rewriting that.

In the AllMusic new web pages are (data) information is really very bad arranged and some information are missing, given the fact, how the data were arranged by the AllMusic old web pages.
Title: Re: AllMovie.com - new movie script
Post by: Ivek23 on June 18, 2012, 06:54:47 am
Good feature of this script is, that it works on old AllMovie URLs. Script of each of these URLs, not deleted or overwritten, so they remain in the URLs box. They also in the URL field added to the new URLs, which script transferred from the AllMovie new web site.

The problem arises where the order URLs such is for example, is this one order of
Quote
Old AllMovie URLs like...
http://www.allmovie.com/work/casablanca-8482 or
http://www.allmovie.com/work/8482
(this url again now operate normally and move to a new AllMovie page)
Quote
Most of the movies in my database can be found in the WayBack Machine web archive using a URL like...
http://web.archive.org/web/http://www.allmovie.com/work/casablanca-8482.
order of the URLs such that the script is looking for information through by WayBack Machine web archive url.

However, where the order of the URLs such an this
Quote
http://web.archive.org/web/http://www.allmovie.com/work/casablanca-8482.
Quote
http://www.allmovie.com/work/casablanca-8482 or
http://www.allmovie.com/work/8482
the script is looking for information by AllMovie new web site,
Title: Re: AllMovie.com - new movie script
Post by: rick.ca on June 18, 2012, 08:25:42 am
I don't understand. I use our AllRovi script to get data from http://www.allrovi.com/movies/movie/casablanca-v8482. I don't see any useful additional data at http://www.allmovie.com/movie/casablanca-v8482/. Rovi abandoned some data that was available on the old site. This data is still available via the Wayback Machine—if the pages were saved—at http://web.archive.org/web/http://www.allmovie.com/work/casablanca-8482. I only use that URL manually; I don't attempt to get the additional data with a script. Thankfully, in most cases, I already have it.

What is very odd is if http://www.allrovi.com/movies/movie/casablanca-v8482 is used manually, or as a link on an AllRovi page (e.g., search results), it's redirected to the new AllMovie page (i.e., both of the first two URL's above go to the same page). But our AllRovi script still works, apparently still accessing the AllRovi pages. I suppose that may only be temporary, and this script will become the only one that works. :-\
Title: Re: AllMovie.com - new movie script
Post by: Ivek23 on June 18, 2012, 11:37:38 am
If I'm not mistaken it for AllRovi need to add this / at the end of the url that redirects to AllRovi web site. If this is not the end of the url, then redirect to AllMovie web site.

For example:

http://www.allrovi.com/movies/movie/casablanca-v8482  redirect to AllMovie

http://www.allrovi.com/movies/movie/casablanca-v8482/    normal at AllRovi
Title: Re: AllMovie.com - new movie script
Post by: Ivek23 on June 18, 2012, 01:28:29 pm
Good feature of this script is, that it works on old AllMovie URLs. Script of each of these URLs, not deleted or overwritten, so they remain in the URLs box. They also in the URL field added to the new URLs, which script transferred from the AllMovie new web site.

The problem arises where the order URLs such is for example, is this one order of
Quote
Old AllMovie URLs like...
http://www.allmovie.com/work/casablanca-8482 or
http://www.allmovie.com/work/8482
(this url again now operate normally and move to a new AllMovie page)
Quote
Most of the movies in my database can be found in the WayBack Machine web archive using a URL like...
http://web.archive.org/web/http://www.allmovie.com/work/casablanca-8482.
order of the URLs such that the script is looking for information through by WayBack Machine web archive url.

However, where the order of the URLs such an this
Quote
http://web.archive.org/web/http://www.allmovie.com/work/casablanca-8482.
Quote
http://www.allmovie.com/work/casablanca-8482 or
http://www.allmovie.com/work/8482
the script is looking for information by AllMovie new web site,
I just wanted to explain and demonstrate how important is actually recording the order of the URLs in PVD url field for data transmission with AllMovie new web pages.

Quote
http://www.imdb.com/title/tt0034583/
http://www.allmovie.com/work/casablanca-8482
http://web.archive.org/web/20090324024706/http://www.allmovie.com/work/casablanca-8482
http://www.allrovi.com/movies/movie/casablanca-v8482
AllMovie New Script works - no data transfer
and redirect AllRovi url to AllMovie


Quote
http://www.imdb.com/title/tt0034583/ 
http://web.archive.org/web/20090324024706/http://www.allmovie.com/work/casablanca-8482
http://www.allmovie.com/work/casablanca-8482
http://www.allrovi.com/movies/movie/casablanca-v8482/
AllMovie New Script works - the transfer of data
and certainly very encouraging, at least so far, that normal works - open AllRovi url at AllRovi.
Title: Re: AllMovie.com - new movie script
Post by: Ivek23 on June 18, 2012, 02:07:24 pm
I don't understand. I use our AllRovi script to get data from http://www.allrovi.com/movies/movie/casablanca-v8482. I don't see any useful additional data at http://www.allmovie.com/movie/casablanca-v8482/. Rovi abandoned some data that was available on the old site. This data is still available via the Wayback Machine—if the pages were saved—at http://web.archive.org/web/http://www.allmovie.com/work/casablanca-8482. I only use that URL manually; I don't attempt to get the additional data with a script. Thankfully, in most cases, I already have it.
The Wayback Machine URL - I have always saved there for check old AllMovie data (if I need a url address, we do not need to look again - a precaution just in case).

I don't understand. I use our AllRovi script to get data from http://www.allrovi.com/movies/movie/casablanca-v8482. I don't see any useful additional data at What is very odd is if http://www.allrovi.com/movies/movie/casablanca-v8482 is used manually, or as a link on an AllRovi page (e.g., search results), it's redirected to the new AllMovie page (i.e., both of the first two URL's above go to the same page). But our AllRovi script still works, apparently still accessing the AllRovi pages. I suppose that may only be temporary, and this script will become the only one that works.
Hopefully, that will have successfully operate both of the scripts.
Title: Re: AllMovie.com - new movie script
Post by: rick.ca on June 18, 2012, 09:45:29 pm
If I'm not mistaken it for AllRovi need to add this / at the end of the url that redirects to AllRovi web site. If this is not the end of the url, then redirect to AllMovie web site.

Now why didn't I think of that? ;)
Title: Re: AllMovie.com - new movie script
Post by: Ivek23 on June 19, 2012, 06:01:31 am
Quote
http://www.imdb.com/title/tt0034583/ 
http://web.archive.org/web/20090324024706/http://www.allmovie.com/work/casablanca-8482
http://www.allmovie.com/work/casablanca-8482
http://www.allrovi.com/movies/movie/casablanca-v8482/
AllMovie New Script works - the transfer of data
and certainly very encouraging, at least so far, that normal works - open AllRovi url at AllRovi.
I use Mozilla Firefox as your default browser. Today I had trouble opening AllRovi URLs because it worked again AllRovi URLs redirect to AllMovie page. A simple solution - I cleaned up history of browser (memory) and again normal works (AllRovi URLs redirect to AllRovi web site).
Title: Re: AllMovie.com - new movie script
Post by: Ivek23 on June 22, 2012, 02:20:10 pm
If I'm not mistaken it for AllRovi need to add this / at the end of the url that redirects to AllRovi web site. If this is not the end of the url, then redirect to AllMovie web site.
I am wrong, part of this statement is not true.

True is, If add this / at the end of the url, that redirect to AllMovie web site. If this is not the end of the url, then movie url redirects to AllRovi web site.
Title: Re: AllMovie.com - new movie script
Post by: Ivek23 on June 23, 2012, 05:06:22 am
Quote
http://www.imdb.com/title/tt0034583/
http://www.allmovie.com/work/casablanca-8482
http://web.archive.org/web/20090324024706/http://www.allmovie.com/work/casablanca-8482
http://www.allrovi.com/movies/movie/casablanca-v8482
redirect AllRovi url to AllMovie

Quote
http://www.imdb.com/title/tt0034583/ 
http://web.archive.org/web/20090324024706/http://www.allmovie.com/work/casablanca-8482
http://www.allmovie.com/work/casablanca-8482
http://www.allrovi.com/movies/movie/casablanca-v8482/
open AllRovi url at AllRovi

Correction for this interpretation - the correct interpretation is as follows:

Quote
http://www.imdb.com/title/tt0034583/ 
http://web.archive.org/web/20090324024706/http://www.allmovie.com/work/casablanca-8482
http://www.allmovie.com/work/casablanca-8482
http://www.allrovi.com/movies/movie/casablanca-v8482/
Redirect AllRovi url to AllMovie.

This example:

Quote
http://www.imdb.com/title/tt0034583/ 
http://web.archive.org/web/20090324024706/http://www.allmovie.com/work/casablanca-8482
http://www.allmovie.com/work/casablanca-8482
http://www.allrovi.com/movies/movie/casablanca-v8482
And works, open AllRovi url at AllRovi.

If it does not work, then do this:
I use Mozilla Firefox as your default browser. Today I had trouble opening AllRovi URLs because it worked again AllRovi URLs redirect to AllMovie page. A simple solution - I cleaned up history of browser (memory) and again normal works (AllRovi URLs redirect to AllRovi web site).
and works.
Title: Re: AllMovie.com - new movie script
Post by: Ivek23 on September 24, 2012, 03:07:37 pm
According to some problems with the Releases page also AllMovie.com new web pages there were also some changes in web pages (some changes in the source code of web pages), were made small changes in AllMovie.com script, the script now works (previously worked, but there was no info transferred data).

Script AllMovie.com(1) attached.

It will also update for AllMovie.com script for other changes on the AllMovie.com web sites (will be more time for that).

[attachment deleted by admin]
Title: Re: AllMovie.com - new movie script
Post by: Ivek23 on December 13, 2012, 09:12:17 am
It will also update for AllMovie.com script for other changes on the AllMovie.com web sites (will be more time for that).

Now I just managed to fix AllMovie.com_new.

Updated:
Removed:

Removed was a ParseDVDreleases, remained a url link to AllMovie Releases tab.
Removed was Characteristics and Themes, because it is now united in Characteristics according to the subcategory which are listed below, with the exception Themes links.


Added to the new:

Repaired  AllMovie.com_new Script  is attached in the first post. (http://www.videodb.info/forum_en/index.php/topic,3154.msg15349.html#msg15349)
Title: Re: AllMovie.com - new movie script
Post by: Ivek23 on December 14, 2012, 02:45:13 pm
Post any comments or questions to AllMovie.com_new Script is can here.
Title: Re: AllMovie.com_new movie script
Post by: rick.ca on December 17, 2012, 02:32:34 am
Both this and the updated AllRovi script work great. Thanks very much for the work you do on these and other scripts, Ivek.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on December 17, 2012, 07:14:36 am
Both this and the updated AllRovi script work great. Thanks very much for the work you do on these and other scripts, Ivek.

Thank you, Rick.
I will do more tests to see if it will be something in need of repair,  then also available via the auto-update system.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on January 13, 2013, 02:52:06 pm
Here is the final AllMovie.com_new script.

Script  AllMovie.com_final  is attached.

[attachment deleted by admin]
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on January 13, 2013, 02:53:02 pm
Quote
Quote
This script has now been released and is available via the program's auto-update system. Run Help > Check for updates and choose AllMovie.com_new from the list.

Quote
Post any comments or questions to AllMovie.com_new Script is can here.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on January 13, 2013, 03:39:54 pm
Anyone who wants to change the current date and time updates, here is a solution, example is for AllMovie.com_new movie script:

I did not like the last part of the code for 
Code: [Select]
//Date ~Updated~ (choose simple or verbose version)

//AddCustomFieldValueByName('Updated', DateToStr(CurrentDateTime)); // Simple
//AddCustomFieldValueByName('Updated', DateToStr(CurrentDateTime) + ' at ' + TimeToStr(CurrentDateTime)); // Verbose
AddCustomFieldValueByName('Updated', DateToStr(CurrentDateTime) + ' at ' + TimeToStr(CurrentDateTime) + ' • ' + SCRIPT_NAME + ' ' + SCRIPT_VERSION); // Annoying


//Get ~mfURL~ or ~URL~

Date was previously seen such:
Code: [Select]
2013-01-13 at 14:17:50
So I switched over to that part of the code
Code: [Select]
procedure ParseMovie(MovieURL : String; HTML : String);
var
curPos, endPos, topPos, L, H, R : Integer;
Date, Name, URL, TmpStr, TmpStr1, TmpStr2, TmpStr3, TmpStr4, TmpStr5 : String;
DateParts: TWideArray;
begin

//Date ~Updated~ (choose simple or verbose version)
Date := DateToStr(CurrentDateTime);
if Date <> '' then
  begin
    ExplodeString(Date, DateParts, '-');
Date := DateParts[2] +'.'+ DateParts[1] +'.'+ DateParts[0];
AddCustomFieldValueByName('Updated', Date);
//AddCustomFieldValueByName('Updated', Date + ' at ' + TimeToStr(CurrentDateTime)); // Verbose
AddCustomFieldValueByName('Updated', Date + ' at ' + TimeToStr(CurrentDateTime) + ' • ' + SCRIPT_NAME + ' ' + SCRIPT_VERSION); // Annoying
  end else
    LogMessage('date not found');

//AddCustomFieldValueByName('Updated', DateToStr(CurrentDateTime)); // Simple
//AddCustomFieldValueByName('Updated', DateToStr(CurrentDateTime) + ' at ' + TimeToStr(CurrentDateTime)); // Verbose
//AddCustomFieldValueByName('Updated', DateToStr(CurrentDateTime) + ' at ' + TimeToStr(CurrentDateTime) + ' • ' + SCRIPT_NAME + ' ' + SCRIPT_VERSION); // Annoying


//Get ~mfURL~ or ~URL~

Date now looks like this:
Code: [Select]
13.01.2013 at 14:17:50
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on March 04, 2013, 09:18:51 pm
Is it just me, or AllMovie_New script doesn't work? Cannot import rating, Studio, Synopsis and Reviews fields that I use?
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on March 05, 2013, 07:46:59 am
Is it just me, or AllMovie_New script doesn't work? Cannot import rating, Studio, Synopsis and Reviews fields that I use?

PVD v0.9.9.21

All of the above work unless Reviews. Try the attached script, if everything works, then I'll uploaded on Download page.

Your version of PVD is ...

[attachment deleted by admin]
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on March 05, 2013, 11:41:42 pm
I apologize. I didn't realize there is no editor's rating as well as Studio's name for a movie El infierno at Allmovie.com. It works, actually.

Sorry, once again and thank you for your assistance!
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on March 06, 2013, 12:41:27 pm
Quote
Is it just me, or AllMovie_New script doesn't work? Cannot import rating, Studio, Synopsis and Reviews fields that I use?
I apologize. I didn't realize there is no editor's rating as well as Studio's name for a movie El infierno at Allmovie.com. It works, actually.

Sorry, once again and thank you for your assistance!

It's okay, for such matters are otherwise does not need to apologize. It is correct to draw attention to the potential problems in the functioning of the script, so other users will not have any problems with data transfers, because eliminating all the possible problems. That's why we're here (the author of this script, the moderator and other users) to help you solve the problem.

Script will be added to the download page today or at the latest tomorrow.

Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on March 06, 2013, 05:06:08 pm
AllMovie.com_new script
v 0.1.1.1.


I fixed ParseReview:
piece of code
Code: [Select]
procedure ParseReview(HTML : String);
var
curPos, endPos : Integer;
TmpStr, TmpStr1, TmpStr2, TmpStr3, TmpStr4, TmpStr5 : String;
begin
curPos := Pos('<div class="tab-title">', HTML);
if curPos < 1 then
Exit;

//~Review~
I switched to this part of the code
Code: [Select]
procedure ParseReview(HTML : String);
var
curPos, endPos : Integer;
TmpStr, TmpStr1, TmpStr2, TmpStr3, TmpStr4, TmpStr5 : String;
begin
curPos := Pos('<div class="tabset-content main-tab-pane">', HTML);
if curPos < 1 then
Exit;

//~Review~

Now ParseReview works.

Notice:
The new version of the script is added to the Download page.
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on April 12, 2013, 08:50:38 pm
AllMovie.com_new script
v 0.1.1.1.


I fixed ParseReviewe

Now ParseReview works.

Notice:
The new version of the script is added to the Download page.


Does this mean reviews can be imported from allmovie.com? If it does mean, I guess custom "Review" field is needed for it?
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on April 13, 2013, 07:28:34 am
Does this mean reviews can be imported from allmovie.com?

Yes, it's true, now you can also Reviews information imported from allmovie.com new page.

If it does mean, I guess custom "Review" field is needed for it?

No, this is not at all a mistake, you guessed correctly in this case. Yes, you really need a custom "Review" field on imports Review information.

Title: Re: AllMovie.com_new movie script
Post by: afrocuban on April 13, 2013, 06:11:13 pm
Thanks a lot Ivek.

Pozdrav iz Beograda
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on April 13, 2013, 06:17:32 pm
Thanks a lot Ivek.

Pozdrav iz Beograda

Welcome.

Enako iz Slovenije.
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on April 16, 2013, 12:45:00 am
I just tested Review importing and it really works great! But, there is an issue. It looks like script imports only first paragraph of Review tab at Allmovie.com.

Checked with http://www.allmovie.com/movie/the-adjustment-bureau-v509764/review

Any help with this, please?
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on April 16, 2013, 06:35:14 am
I just tested Review importing and it really works great! But, there is an issue. It looks like script imports only first paragraph of Review tab at Allmovie.com.

Checked with http://www.allmovie.com/movie/the-adjustment-bureau-v509764/review

Any help with this, please?

I apologize, be patient. It will be a short wait, it requires more testing. At the moment I do not have time, maybe in a few weeks.
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on April 16, 2013, 11:35:18 am
Thanks once again for all your contribution and work.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on April 16, 2013, 06:18:21 pm
Thanks once again for all your contribution and work.

Thank you found the error, I did a little cosmetic correction. Try these attached AllMovie.com 0.1.1.2 script version and let us know if the script is working properly now. Is not tested on other movies, except for your movie, which is the link mentioned above.

[attachment deleted by admin]
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on April 17, 2013, 01:35:43 am
It's just perfect now, Ivek! Great work.

Cheers
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on April 30, 2013, 06:16:07 am
I changed a little piece of code to Review info. Now I wonder if this also works fine. I wonder also what is now the difference in text in Review custom field between AllMovie.com 0.1.1.2 script version and AllMovie.com 0.1.1.3 script version. In AllMovie.com 0.1.1.2 script version the transferred original Review information where the Review fields on web pages added pictures. In AllMovie.com 0.1.1.3 script version the passed unseen Review information,  which is not visible in Review fields on web pages. They are, however Review information in both cases exactly the same written. I am interested in your opinion because I'm a better version then added to the Download page.

AllMovie.com 0.1.1.3 script version is attached.

[attachment deleted by admin]
Title: Re: AllMovie.com_new movie script
Post by: rick.ca on April 30, 2013, 07:00:48 am
I haven't tested thoroughly, but for the one movie I tried...The old version only got the first paragraph of the review. Maybe is failed because there was a photo in the second paragraph. The new version got the whole review.

BTW, neither version found the movie until I added the URL manually.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on April 30, 2013, 02:23:00 pm
BTW, neither version found the movie until I added the URL manually.

Yes, the movie in the search results may not have been on the first page on which the script returns results. The problem of finding results at AllMovie new web pages is that the movie you are looking for, shown only the first 10 results on the first search page. If the search results in more than 10 hits, it is here the second page or multiple pages with 10 hits. The remaining pages of the search hits are AllMovie script not found and is required to manually enter the URL to the script then finds. These errors, which rarely occurs (at least I think so) in the search results, I do not know how to resolve this problem. Maybe someone can help solve this problem?
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on April 30, 2013, 02:24:38 pm
Ivek,

v0113 is better than v0112. It now deletes extra paragraph spaces added when importing to a "Review" field, where the photos were on the site review tab. Great work, thank you!

I have a very, very personal and selfish appeal to you. Is it reasonable for you to save All Movie synopsis to some other field by default ("Comments", for eample). Is it possible, in addition to offer custom field for synopsis. Thanks in advance.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on April 30, 2013, 03:42:56 pm
Ivek,

v0113 is better than v0112. It now deletes extra paragraph spaces added when importing to a "Review" field, where the photos were on the site review tab. Great work, thank you!

Thank you.

I have a very, very personal and selfish appeal to you. Is it reasonable for you to save All Movie synopsis to some other field by default ("Comments", for eample). Is it possible, in addition to offer custom field for synopsis. Thanks in advance.

No problem, can be transferred to a custom field.

There are several possibilities:

Some of it is added to the script.

For example:
Quote
Code: [Select]
if (TmpStr4 = 'synopsis') AND (Pos('©', TmpStr2) = 0) then
AddFieldValue(mfDescription, TmpStr2 + #13 + '— ' + TmpStr3)
else
if (TmpStr4 <> 'synopsis') OR (Pos('©', TmpStr2) = 1) then
LogMessage(' Synopsis: Not available');

if (TmpStr4 = 'synopsis') AND (Pos('©', TmpStr2) = 0) then
AddCustomFieldValueByName('AllMovie Synopsis', TmpStr2 + #13 + '— ' + TmpStr3)
else
if (TmpStr4 <> 'synopsis') OR (Pos('©', TmpStr2) = 1) then
LogMessage(' Synopsis: Not available');

Code: [Select]
//if (TmpStr4 = 'synopsis') AND (Pos('©', TmpStr2) = 0) then
// AddFieldValue(mfDescription, TmpStr2 + #13 + '— ' + TmpStr3)
//else
// if (TmpStr4 <> 'synopsis') OR (Pos('©', TmpStr2) = 1) then
// LogMessage(' Synopsis: Not available');

if (TmpStr4 = 'synopsis') AND (Pos('©', TmpStr2) = 0) then
AddCustomFieldValueByName('AllMovie Synopsis', TmpStr2 + #13 + '— ' + TmpStr3)
else
if (TmpStr4 <> 'synopsis') OR (Pos('©', TmpStr2) = 1) then
LogMessage(' Synopsis: Not available');

Code: [Select]
if (TmpStr4 = 'synopsis') AND (Pos('©', TmpStr2) = 0) then
AddCustomFieldValueByName('AllMovie Synopsis', TmpStr2 + #13 + '— ' + TmpStr3)
else
if (TmpStr4 <> 'synopsis') OR (Pos('©', TmpStr2) = 1) then
LogMessage(' Synopsis: Not available');

Another simple solution is to add "AllMovie Synopsis" custom field and in the settings set the way you AllMovie synopsis transferred to this custom field (see example in the attached picture - sshot-0, sshot-1 and sshot-2).

[attachment deleted by admin]
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on April 30, 2013, 05:40:04 pm
Thanks.

Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on April 30, 2013, 07:20:17 pm
Thanks.

Thank you for all the feedback.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 01, 2013, 07:54:50 am
BTW, neither version found the movie until I added the URL manually.

There are also variants of the script did not find the movie:
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 01, 2013, 07:56:07 am
AllMovie.com_new script
v 0.1.1.3.


I fixed all ParseReview:
piece of code

Code: [Select]
//~Review~

curPos := PosFrom('<span>', HTML, curPos);
endPos := PosFrom('</span>', HTML, curPos);
TmpStr5 := TextBetween(HTML, '<span>', '</span>', True, curPos);
curPos := PosFrom('<span>by', HTML, curPos);
endPos := PosFrom('</span>', HTML, curPos);

TmpStr3 := TextBetween(HTML, '<span>by ', '</span>', True, curPos)

curPos := PosFrom('<strong>', HTML, curPos);
endPos := PosFrom('</strong>', HTML, curPos);
TmpStr4 := TextBetween(HTML, '<strong>', '</strong>', True, curPos);

curPos := PosFrom('<p>', HTML, curPos);
endPos := PosFrom('</p>', HTML, curPos);
TmpStr := Copy(HTML, curPos, endPos - curPos);
TmpStr1 := StringReplace(TmpStr, ' -- ', '—', True, True, False);
TmpStr2 := StringReplace(TmpStr1, ' --- ', '—', True, True, False);
TmpStr := StringReplace(TmpStr2, '--', '—', True, True, False);
TmpStr1 := StringReplace(TmpStr, #13#13#13#13, #13#10#13#10, True, True, False);
TmpStr2 := RemoveTagsEx(TmpStr1);

AddCustomFieldValueByName('Review', TmpStr2 + #13 + '—' + TmpStr3);
changed in this part of the code
Code: [Select]
//~Review~

//curPos := PosFrom('<span>', HTML, curPos);
//endPos := PosFrom('</span>', HTML, curPos);
//TmpStr5 := TextBetween(HTML, '<span>', '</span>', True, curPos);
//curPos := PosFrom('<span>by', HTML, curPos);
//endPos := PosFrom('</span>', HTML, curPos);

//TmpStr3 := TextBetween(HTML, '<span>by ', '</span>', True, curPos)

//curPos := PosFrom('<strong>', HTML, curPos);
//endPos := PosFrom('</strong>', HTML, curPos);
//TmpStr4 := TextBetween(HTML, '<strong>', '</strong>', True, curPos);

//curPos := PosFrom('<p>', HTML, curPos);
//endPos := PosFrom('</div>', HTML, curPos);
//TmpStr := Copy(HTML, curPos, endPos - curPos);
//TmpStr1 := StringReplace(TmpStr, ' -- ', '—', True, True, False);
//TmpStr2 := StringReplace(TmpStr1, ' --- ', '—', True, True, False);
//TmpStr := StringReplace(TmpStr2, '--', '—', True, True, False);
//TmpStr1 := StringReplace(TmpStr, #13#13#13#13, #13#10#13#10, True, True, False);
//TmpStr2 := RemoveTagsEx(TmpStr1);

//AddCustomFieldValueByName('Review', TmpStr2 + #13 + '—' + TmpStr3);

curPos := PosFrom('<span itemprop="itemreviewed">', HTML, curPos);
endPos := PosFrom('</span>', HTML, curPos);
TmpStr5 := TextBetween(HTML, '<span itemprop="itemreviewed">', '</span>', True, curPos);
curPos := PosFrom('<span itemprop="rating">', HTML, curPos);
endPos := PosFrom('</span>', HTML, curPos);
TmpStr4 := TextBetween(HTML, '<span itemprop="rating">', '</span>', True, curPos);
curPos := PosFrom('<span itemprop="reviewer">', HTML, curPos);
endPos := PosFrom('</span>', HTML, curPos);

TmpStr3 := TextBetween(HTML, '<span itemprop="reviewer">', '</span>', True, curPos)

curPos := PosFrom('<span itemprop="description">', HTML, curPos)+ 29;
endPos := PosFrom('</span>', HTML, curPos);
TmpStr := Copy(HTML, curPos, endPos - curPos);

AddCustomFieldValueByName('Review', TmpStr + '—' + TmpStr3);

Prior to this change in the code, the transmission of info only to the first paragraph from the Review tab. After this change in the code, the transmission of info for all Review paragraphs from the Review tab (full review).

Notice:
The new version of the script is added to the Download page.
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on May 01, 2013, 12:19:00 pm
Thanks a lot Ivek. It works just as you described it.

Now, could you consider to create a "quick" allmovie script, just like you did for IMDb (http://www.videodb.info/forum_en/index.php/topic,3282.msg16333.html#msg16333), for example? Just url, title and rating, let's say.

At least, I'd adapt one for my needs, if you'd describe me what "parts" of the code are obligatory for the script to work, beside url, title and rating sections. You can just publish script that works but imports nothing ("dummy" one, and I'd compare two scripts and set it for my needs. Don't laugh, I just don't know anything about programming, some basic, pascal and FORTRAN 25 years ago, and that's all, but helpful. ;D

This I need because I'm planning to import allmovie data for my all movies (~6000), and since it's impossible silent mode on to work with your script, I'd have to spend as less as possible time first to get urls for each single entry. In a second row, I'd turn the silent mode on, and let your full script to work the rest.

Thanks in advance.
Title: Re: AllMovie.com_new movie script
Post by: rick.ca on May 01, 2013, 02:18:51 pm
Quote
I'd have to spend as less as possible time first to get urls for each single entry.

You're not likely to save more time than what you're asking Ivek to spend. Run run the script overnight and see what you've got in the morning.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 01, 2013, 03:52:03 pm
Now, could you consider to create a "quick" allmovie script, just like you did for IMDb (http://www.videodb.info/forum_en/index.php/topic,3282.msg16333.html#msg16333), for example? Just url, title and rating, let's say.

You are really one big "Lucky" and you really are very lucky because I was able to fulfill your request.

AllMovie.com_simple script contains, in addition to your wishes, contains a year and a poster. Otherwise, it would also be possible to script would not work properly, if year and the poster would not be added there.

If there is anything superfluous to make this easy in the script block as shown in the attached code snippet below:
Code: [Select]
//AddCustomFieldValueByName('Updated', DateToStr(CurrentDateTime));
AllMovie.com_simple script is attached.

[attachment deleted by admin]
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on May 01, 2013, 09:04:50 pm
Quote
You are really one big "Lucky" and you really are very lucky because I was able to fulfill your request.

Just let me know when you're in Belgrade. Beer's on me!  ;)
I don't understand the part about "Realeses/Features", but never mind. Thanks once again.

Quote
You're not likely to save more time than what you're asking Ivek to spend. Run run the script overnight and see what you've got in the morning.

Rick, can you clarify the scenario, please. I'm all ears (In case I wasn't the clear one, I don't have any allmovie record so far, so nothing will happen with silent mode on).
Title: Re: AllMovie.com_new movie script
Post by: rick.ca on May 01, 2013, 11:58:11 pm
Quote
Rick, can you clarify the scenario, please. I'm all ears (In case I wasn't the clear one, I don't have any allmovie record so far, so nothing will happen with silent mode on).

Even if a script is getting just the URL, it's going to download at least the main page. To get all the information, it will have to download a few more pages (what you see as 'tabs' on the main page). But that will only add a few seconds for each movie.

It's been a long time for me, but I thought these scripts did a reasonable job of returning unique movies (based on a given [Title] and [Year]) when run in silent mode. To the extent that's not true and you're having to run the script manually (to choose the correct movie), why defer getting all the information when it only takes a few seconds more?
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on May 02, 2013, 12:52:13 am
6000 movies times few seconds more...  :-\

I agree with you, it sounds logic to import data for the unique records found, though...

EDIT: I just managed to import a movie this way: My Wrongs 8245-8249 and 117 (http://www.allmovie.com/movie/my-wrongs-8245-8249-and-117-v320107). But it's too unique even for the uniques, it seems :o
Title: Re: AllMovie.com_new movie script
Post by: rick.ca on May 02, 2013, 01:21:15 am
Quote
I agree with you, it sounds logic to import data for the unique records found, though...


...it would be too easy? ???
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 02, 2013, 07:30:35 am
Quote
You are really one big "Lucky" and you really are very lucky because I was able to fulfill your request.

Just let me know when you're in Belgrade. Beer's on me!  ;)

Thanks for the offer, but very difficult, I doubt that I will ever even come to Belgrade. The reason - it is just a little too far for me in recent times (I am partially disabled person due to amblyopia and already almost 10 years without a job).

BTW: Already we are in the month of love, May, therefore, a beautiful and warm greetings from Slovenia.
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on May 02, 2013, 11:38:13 am
Zelo mi je žal, da slišim slabe stvari o dobrih ljudi, kot ste vi.

My all the best, Ivek.
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on May 02, 2013, 11:57:51 am
Quote from: rick.ca
Run run the script overnight and see what you've got in the morning.

So, just to let you know, I did what you suggested to me, and this morning I found 1530 records with allmovie data, which is about 27% of all. Quite satisfied. Thank you for your time, too.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 02, 2013, 12:22:49 pm
Zelo mi je žal, da slišim slabe stvari o dobrih ljudi, kot ste vi.

My all the best, Ivek.

Hvala.

Thanks.
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on May 02, 2013, 08:24:12 pm
Quote
The remaining pages of the search hits are AllMovie script not found and is required to manually enter the URL to the script then finds. These errors, which rarely occurs (at least I think so) in the search results, I do not know how to resolve this problem.

I tested the script in silent mode off and what I can say is that about some 10-15% of the movies aren't found in the first ten hits (on the firs page). What I noticed is, that if I used google to search allmovie.com for a specific title, I got 100% hits in first two results (the movie's always correct, but the first result might be /releases). Is it possible to use this information to improve the script?

Examples of the movies that aren't listed on the first ten search results at allmovie.com:

http://www.allmovie.com/movie/the-housemaid-v317173
http://www.allmovie.com/movie/el-camino-v434425
http://www.allmovie.com/movie/the-expendables-v474338
http://www.allmovie.com/movie/shanghai-v425881/
http://www.allmovie.com/movie/the-outlaw-v569124
http://www.allmovie.com/movie/loose-change-9-11-an-american-coup-v492684
http://www.allmovie.com/movie/the-life-and-death-of-a-porno-gang-v523933

Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 03, 2013, 09:29:54 am
http://www.allmovie.com/movie/the-housemaid-v317173
http://www.allmovie.com/movie/el-camino-v434425

These two URLs script (AllMovie or AllRovi script) in a single search finds is verified.

http://www.allmovie.com/movie/the-expendables-v474338
http://www.allmovie.com/movie/the-outlaw-v569124

These URLs script (AllMovie or AllRovi script) in a single search not at all found, it is checked. It is not in the search results on the web site.

http://www.allmovie.com/movie/loose-change-9-11-an-american-coup-v492684

This url script in a single search not at all found, it is checked. It is AllRovi script finds.

http://www.allmovie.com/movie/the-life-and-death-of-a-porno-gang-v523933

The reason, why script
  • It is possible that the film you are looking to contain inappropriate content (adult movies) and filter for the children of this film does not show in the list of search results (filter is already in primary settings). As far as I know, AllRovi websites use this filter and AllMovie new website also use this filter.
absolutely not found.

http://www.allmovie.com/movie/shanghai-v425881/

This url script in a single search not at all found, verified, because on the next page in the search results.

With a Google search, all URLs to find.

Is it possible to use this information to improve the script?

In this regard, it is as follows:
probably that or not, I do not know, I'm not a programmer, I do not have the right of replies to it.

I suggest a small solution for certain movies. I arranged AllRovi script that will find certain movies. In the URL field will instead AllRovi url added AllMovie url address. He added the title and the year of the film, but unfortunately it does not rating reviews

AllRovi_simple script is attached.

[attachment deleted by admin]
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on May 03, 2013, 01:48:52 pm
http://www.allmovie.com/movie/the-housemaid-v317173
http://www.allmovie.com/movie/el-camino-v434425

These two URLs script (AllMovie or AllRovi script) in a single search finds is verified.

Unfortunately it's not

For the first movie, original title is "Hanyo", and as I understood the script searches by <origtitle>, not by <title> - which is proved in picture 1.jpg attached by search within PVD, also the same search AllMovie.com by origtitle (http://www.allmovie.com/search/all/hanyo) . Why then,script searches by original title, but not by <title>, cause obviously allmovie.com has no accurate database of original titles in "ALTERNATE TITLE" FIELD? Wouldn't be more reasonable then to search by title?

It's the same with the second movie. It's original title isn't "El camino", but "Camino", that's why it couldn't have been found.

But, look at the Google with "Hanyo" only-term search (https://www.google.com/search?safe=off&client=firefox-a&hs=Xtt&rls=org.mozilla:en-US:official&biw=797&bih=381&q=hanyo+site:allmovie.com&oq=hanyo+site:allmovie.com&gs_l=serp.3...8178312.8182597.0.8183066.13.11.2.0.0.0.90.852.11.11.0...0.0...1c.1.12.serp.SP9_ar1Sn_Y). Perfect match? BUT HOW THE HELL GOOGLE FOUND "HANYO" ON ALLMOVIE, WHEN "HANYO" ISN'T STATED ANYWHERE ON ALLMOVIE.COM FOR THE MOVIE FROM 1960????

Is it possible to incorporate google search results in allmovie script, not to search allmovie directly, but via google, so it extracts all allmovie's url from the first ten google results that have "vxxxxxx", then deletes everything after "-vxxxxx" in such urls, and returm us search results? Such a script for all movie would hit all original titles and adult genre in first couple of matches (depending on how often original title is used in cinematography).

Thanks for the rovi simple script anyway, but still no luck with these titles!





[attachment deleted by admin]
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 03, 2013, 07:19:47 pm
http://www.allmovie.com/movie/the-housemaid-v317173
http://www.allmovie.com/movie/el-camino-v434425

These two URLs script (AllMovie or AllRovi script) in a single search finds is verified.

Unfortunately it's not

For the first movie, original title is "Hanyo", and as I understood the script searches by <origtitle>, not by <title> - which is proved in picture 1.jpg attached by search within PVD, also the same search AllMovie.com by origtitle (http://www.allmovie.com/search/all/hanyo) . Why then,script searches by original title, but not by <title>, cause obviously allmovie.com has no accurate database of original titles in "ALTERNATE TITLE" FIELD? Wouldn't be more reasonable then to search by title?

If you access the Internet over the url to the film page and with this page, copy the title of the movie in PVD, you will find the script (movie).

Is it possible to incorporate google search results in allmovie script, not to search allmovie directly, but via google, so it extracts all allmovie's url from the first ten google results that have "vxxxxxx", then deletes everything after "-vxxxxx" in such urls, and returm us search results? Such a script for all movie would hit all original titles and adult genre in first couple of matches (depending on how often original title is used in cinematography).

Sorry, too demanding application for my knowledge in computer science (I'm no programmer, I'm just a computer amateur, self-taught without a single hour of training in computer science). For my part the answer is no, maybe you can help someone else in this matter.

In the search results the you can in help also Bing_SearchMulti_All script that gets to the right connections or access to the web site and also to url addresses. Bing_SearchMulti_All script displays URLs in the search results, but does not transfer anything.

Bing_SearchMulti_All script is attached.

[attachment deleted by admin]
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 04, 2013, 06:43:52 am
I fixed search in Bing_SearchMulti_All script. Script now find search results for both AllMovie as well as for AllRovi.

Bing_SearchMulti_All script is attached.

[attachment deleted by admin]
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 04, 2013, 03:20:39 pm
I tried to manipulate the AllMovie_simple script with Bing search results, it has been successful and script it works. I also tried the Google search results, so far unsuccessfully. This is now the basis for a script that someone might be able to edit the script with Google search results.

AllMovie.com_Bing_Search script is attached.

[attachment deleted by admin]
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on May 04, 2013, 04:02:11 pm
:)
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on June 01, 2014, 08:25:24 am
AllMovie.com_new script
v 0.1.1.4.


For  ~Mood links~ :

I made several small corrections in the Mood links code in ParseMovie procedure for correctly download url links for Moods, if the links are available at wayback.archive.org  (http://archive.org/web/).
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on June 01, 2014, 08:26:31 am
AllMovie.com_new script
v 0.1.1.5.


I also added an Alternate title in ParseMovie procedure for the transfer of alternate titles of movies, if they are present at AllMovie movie web sites.

Code: [Select]
//~Alternate title~

TmpStr := HTMLValues(HTML,
'<dt>alternate title</dt>', '</dd>', //ItemEnd was '<dt>'
'<li>', '</li>',
', ', endPos);
AddCustomFieldValueByName('Alternate title', TmpStr);

Notice:
The new version of the script is added to the Download page.


Appendix:

Now it is added to the correct script to download page.
Title: Re: AllMovie.com_new movie script
Post by: UtNut on June 01, 2014, 04:05:30 pm

Many thanks as always Ivek
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on June 01, 2014, 04:19:26 pm

Many thanks as always Ivek

Thanks.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on September 21, 2014, 05:54:38 pm
I fixed search in Bing_SearchMulti_All script. Script now find search results for both AllMovie as well as for AllRovi.

I fixed search results for Bing_SearchMulti_AllMovie script - version 0.0.0.3
Script find now search result for AllMovie. Script displays URLs in the search results, but does not transfer anything.


Bing_SearchMulti_AllMovie script is attached.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on September 21, 2014, 06:07:50 pm
I tried to manipulate the AllMovie_simple script with Bing search results, it has been successful and script it works.

AllMovie.com_simple_Bing_Search script - version 0.1.1.0
 
AllMovie.com_simple_Bing_Search script transfer the info on the movie title, year, rating and poster.

AllMovie.com_simple_Bing_Search script is attached.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on March 02, 2015, 03:09:47 pm
AllMovie.com_new script
v 0.1.2.0.


Have been made some changes in search results, namely, that it is now to find a movie title, which is not listed on the first page of search results, but on the other sides.

Changes in the AllMovie.com_new script:
Code: [Select]
//Script data
SCRIPT_VERSION = '0.1.2.0';
SCRIPT_NAME = 'AllMovie.com_new';
SCRIPT_DESC = '[EN] Get Movie Information from AllMovie.com_new page';
SCRIPT_LANG = $09; //English
SCRIPT_TYPE = stMovies;

BASE_URL = 'http://www.allmovie.com';
      RATING_NAME = 'AllMovie';
//      SEARCH_STR = 'http://www.allmovie.com/search/movies/%s';
CODE_PAGE = 65001; //Use 0 for Autodetect

//User Options
GET_ACTORS = True; //Set to False to ensure ~ctActors~ not added even if 'Overwrite fields' setting allows
GET_DURATION = True; //Set to False to ensure ~mfDuration~ not set even if 'Overwrite fields' setting allows
//Note the program will overwrite this with the actual media duration in any case
GET_POSTER = True; //Set to False if posters not wanted (or to handle bad image URL causing HTTP 404 error)
GET_RATING = True; //Set to False to ensure ~mfRating~ not set even if 'Overwrite setting' fields setting allows
GET_THEMES = True; //Set to False to ensure ~mfCategory~ not added even if 'Overwrite fields' setting allows


//Global variables
var
ELI, I : Integer;
MovieName, PageSite : String;
Mode : Byte;
ExtraLinks : array [smCast..smPoster] of String;
TabMovieName, TabNumber, TabPageSite, TabPage : TwideArray;

Code: [Select]
//function GetDownloadURL : AnsiString;
//begin
// if (Mode = smSearch) then
// Result := SEARCH_STR
// else
// Result := ExtraLinks[Mode];
//end;

function GetDownloadURL : AnsiString;
Var
URLSearch,URLSearch1,URLSearch2: String;
begin
//Get Name of movie to search :               
    MovieName := GetFieldValue(2);
    Explodestring(MovieName,TabMovieName,#32);
    MovieName := #43;
    For I:=low(TabMovieName) to High(TabMovieName) do
    Begin
    MovieName := MovieName  +  TabMovieName[I] + #43;
    end;

URLSearch1 := 'http://www.allmovie.com/search/movies/'+MovieName+'/all/10';
    LogMessage('URL page recherche : '+ URLSearch1);
URLSearch := 'http://www.allmovie.com/search/movies/'+MovieName;
    LogMessage('URL page recherche : '+ URLSearch);

if (Mode = smSearch) then
Result := URLSearch1
else
Result := ExtraLinks[Mode];
if (Mode = smSearch) then
Result := URLSearch
else
Result := ExtraLinks[Mode];
end;

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 := ['10', '20', '30', '40', '50', '60', '70', '80', '90', '100'];
//List of other page site number where search page :
TabPage := ['2', '3', '4', '5', '6', '7', '8', '9', '10','11'];
 
curPos := Pos('<div id="search-results" class="all">', HTML);
// curPos := Pos('div class="results-section movies">', HTML);
if curPos < 1 then
Exit;

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

curPos := PosFrom('<a href="http://www.allmovie.com/movie/', HTML, curPos);
while curPos > 0 do begin
endPos := PosFrom('" class="tool-tip" data-objectid="', HTML, curPos);
URL := Copy(HTML, curPos + 9, endPos - curPos - 9);

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

curPos := PosFrom('</a>', HTML, curPos)+24;
endPos := PosFrom('</dt>', 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="http://www.allmovie.com/movie/', HTML, curPos);
end;

   
//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];
    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+'/all/' + TabNumber[I];
//AddSearchResult('Search in '+MovieName+' on AllMovie.com ',TabNumber[I],'',URL,'');
  end;
    Begin
URL := 'http://www.allmovie.com/search/movies/'+MovieName+'/all/';
AddSearchResult('Search in '+MovieName+' on AllMovie.com ','Page 1','',URL,'');
  end;
//List of other page site number where search page :
//    PageSite := GetFieldValue(0);
//    Explodestring(PageSite,TabPageSite,#32);
//    PageSite := '';
    For I := Low(TabPage) to High(TabPage) do
    Begin
//PageSite := PageSite+TabPage[I];
URL := 'http://www.allmovie.com/search/movies/'+MovieName+'/all/' + TabNumber[I];
  AddSearchResult('Search in '+MovieName+' on AllMovie.com ','Page '+TabPage[I],'',URL,'');
  //AddSearchResult('Search in '+MovieName+' on AllMovie.com '+TabPage[I],TabNumber[I],'',URL,'');
    //AddSearchResult('Search in '+MovieName+' on AllMovie.com ',TabPage[I],'',URL,'');
   end;
//    Begin
// URL := 'http://www.allmovie.com/search/movies/'+MovieName+'/all/';
// AddSearchResult('Search in '+MovieName+' on AllMovie.com ','1','',URL,'');
//  end;

end;

Notice:
The new version of the script is added to the Download page.
Title: Re: AllMovie.com_new movie script
Post by: UtNut on March 03, 2015, 06:03:13 pm

I love this script, I can now see 11 page numbers being displayed...
Many thanks.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on March 03, 2015, 07:51:24 pm

I love this script, I can now see 11 page numbers being displayed...
Many thanks.

Thank you, of course, I'm also glad your positive feedback.
Title: Re: AllMovie.com_new movie script
Post by: UtNut on April 17, 2015, 11:15:10 am
Looks like Allmovie had a major change of their website, hence the script doesn't work any more :-(.
Any chance you could make the script work again?
Mtia.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on April 17, 2015, 03:27:38 pm
Looks like Allmovie had a major change of their website, hence the script doesn't work any more :-(.
Any chance you could make the script work again?
Mtia.

Yes, it is true, a lot of changes (http://www.allmovie.com/), I do not know, when we will be able to edit the AllMovie script. Currently, the best of my time and the current back problems allow it regulates other script. I hope that by October, AllMovie script only organized and will be operated.

Thank you for your patience and waiting for the corrected AllMovie script.
Title: Re: AllMovie.com_new movie script
Post by: UtNut on May 03, 2015, 05:43:12 pm

Does that mean you have problems with your back? If so, I'm sorry to hear that.

My late reply shows that I'm full of patience and it's great to learn you will get the script working again in the near future, no rush on my account please.

In fact, I just finished to enter all my movies in PVD when AllMovie decided to change their website....Lucky me.

Thanks for all the support.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 03, 2015, 06:18:53 pm
Does that mean you have problems with your back? If so, I'm sorry to hear that.

Thank you for this:
If so, I'm sorry to hear that.

Now it has been past and is ok, but sometimes this is happening to me for to the repeat these problems (once smaller, second major, now was that the second).

My late reply shows that I'm full of patience and it's great to learn you will get the script working again in the near future, no rush on my account please.

I will try to operate again unless the undue difficulty, we will see how to proceed.

In fact, I just finished to enter all my movies in PVD when AllMovie decided to change their website....Lucky me.

It was really lucky ...

Thanks for all the support.

Welcome.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 16, 2015, 08:23:24 pm
AllMovie.com_new (2) script
v 0.1.2.1.


Yes, it is true, a lot of changes (http://www.allmovie.com/), I do not know, when we will be able to edit the AllMovie script. Currently, the best of my time and the current back problems allow it regulates other script. I hope that by October, AllMovie script only organized and will be operated.

Thank you for your patience and waiting for the corrected AllMovie script.

There is to test AllMovie.com (2) script to you can try out how it works now.
Feedback is very welcome, especially about errors in the transmission of information (the movie title and url link, please).

Script is the attached.
Title: Re: AllMovie.com_new movie script
Post by: UtNut on May 21, 2015, 03:02:22 pm
Wow Ivek, its magic, you've done it again.

Script works perfect on my side using PVD v0.9.9.21  and PVD Download Manager as skin. I got all the info I want e.g. rating, summary incl name (which I like),  details with url, country, duration, think the tags are going into category. Credits are good, so is release info. There's something funny happening in the Video Data Tab in File Information it imports AllMovie DVD Releases as a link in Features.
I actually like that, was that on purpose?
Title: Re: AllMovie.com_new movie script
Post by: UtNut on May 21, 2015, 03:27:35 pm
Was thinking the last bit is a bit cryptic, so here's an image to support it.
Fyi, the link works and goes directly to what is says.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 21, 2015, 07:46:17 pm
Wow Ivek, its magic, you've done it again.

Script works perfect on my side using PVD v0.9.9.21  and PVD Download Manager as skin. I got all the info I want e.g. rating, summary incl name (which I like),  details with url, country, duration, think the tags are going into category. Credits are good, so is release info.

Thanks. I'm glad for the positive feedback.

There's something funny happening in the Video Data Tab in File Information it imports AllMovie DVD Releases as a link in Features.
I actually like that, was that on purpose?

This was already in AllRovi script (http://www.videodb.info/forum_en/index.php/topic,3862.msg18067.html#msg18067), as in previous AllMovie script 0.1.2.0
version (http://www.videodb.info/forum_en/index.php/topic,3862.msg19082.html#msg19082)
, it is also now because I did not name changed (not normal field names as well as not a custom field names).

In the short term it can expected next AllMovie script version, which will be available for testing, perhaps by the end of this week, when I make a few more tests and maybe some additional information transmission, so little you see, if anything new.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 21, 2015, 07:51:07 pm
Was thinking the last bit is a bit cryptic, so here's an image to support it.
Fyi, the link works and goes directly to what is says.

The answer to this is below:

This was already in AllRovi script (http://www.videodb.info/forum_en/index.php/topic,3862.msg18067.html#msg18067), as in previous AllMovie script 0.1.2.0
version (http://www.videodb.info/forum_en/index.php/topic,3862.msg19082.html#msg19082)
, it is also now because I did not name changed (not normal field names as well as not a custom field names).
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 23, 2015, 04:33:23 pm
AllMovie.com_new (3) script
v 0.1.2.3.


There is to test AllMovie.com (3) script with many corrections in the transfer of information.

CustomField :
Code: [Select]
AllMovie data: PVD field: FN: Type/Comments:
-------------- --------- -- -------------
Actors ~ctActors~ 1, 3 credits (if GET_ACTORS true)
Alternate title ~Alternate title~ memo
AMG ID ~AMG ID~ short text
Awards ~AllMovie Awards~ memo (link to AllMovie Awards tab)
Cast ~Cast~ memo
Crew ~Crew~ memo
Category ~Category.AllMovie~ multiselect list
—not to be confused with ~mfCategory~ (used for 'Themes')
Characteristics
~Moods~ 2 multiselect list (from 'Characteristics')
AND ~Mood links~ memo (hyperlinks to AllMovie mood pages
—if available in web archive
~Keywords~ 2 memo (from 'Characteristics')
~Attributes~ 2 multiselect list (from 'Characteristics')
Themes from 'Characteristics'
~mfCategory~ 1 standard multiselect list (if GET_THEMES true) (from 'Characteristics')
OR ~Themes~ 2 multiselect list (from 'Characteristics')
AND ~Themes links~ 2 memo (hyperlinks to AllMovie themes pages)
Country ~mfCountry~ 1 standard multiselect list
OR ~Country~ 2 multiselect list
Cover-art ~Poster~ 1, 3 standard (if GET_POSTER true)
Directed by ~ctDirectors~ 1 standard multiselect list
Flags ~Flags~ multiselect list
Genres ~mfGenre~ 1 standard multiselect list
OR ~Genres~ 2 multiselect list
AND ~Genre links~ memo (links to AllMovie Genre page)
MPAA rating ~MPAA rating~ short text
Produced by ~mfStudio~ 1 standard short text
OR ~Produced by~ 2 multiselect list
Review ~Review~ memo
Release date ~Released~ short text (multiple dates)
//OR Released ~Released~ short //text (more common single date)
Releases ~mfFeatures~ 1 standard memo (link to AllMovie Releases tab)
Released by ~Released by~ short text
Rovi rating ~mfRating~ 1, 3 'Additional rating' named 'AllMovie.new' (if GET_RATING true)
OR ~AllMovie rating~ 2 rating
Run time ~mfDuration~ 1, 3 standard number (if GET_DURATION true)
OR ~Run time~ 2 number (minutes)
Synopsis ~mfDescription~ standard memo
—use PVD preference to save in ANY available memo field
Sub-Genres ~Sub-Genres~ multiselect list
OR ~Sub-Genre links~ memo (links to AllMovie page)
Title ~mfTitle~ 1 standard short text
OR ~Title~ 2 short text
Year ~mfYear~ 1 standard number (from AllMovie 'Title (Year)' heading)
OR ~Year~ 2 short string
Updated ~Updated~ long text
URL ~mfURL~ 1 standard memo
OR ~URL~ 2 memo

New Added in Custom Field:

CustomField :

AllMovie Related                        ----> Memo
Search Movie results                        ----> Memo


Script is the attached.
Title: Re: AllMovie.com_new movie script
Post by: UtNut on May 23, 2015, 06:00:45 pm

Brilliant, thanks enormously. I wouldn't use the related function, but I'd guess this is a great thing for others using Allmovie data. Kudos to you.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 23, 2015, 07:30:12 pm
Brilliant, thanks enormously.

Thanks, UtNut.

I wouldn't use the related function, but I'd guess this is a great thing for others using Allmovie data.

Optionally, it's just Related url link to the AllMovie web pages.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 23, 2015, 08:00:08 pm
I forgot to mention that the added link to the Amazon web site to search movie posters.

CustomField :

Amazon                        ----> Memo
Title: Re: AllMovie.com_new movie script
Post by: UtNut on May 24, 2015, 12:24:39 pm
Excellent, they got some good posters there.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 29, 2015, 11:48:26 am
AllMovie.com_new (4) script
v 0.1.2.3.


There is to test AllMovie.com (4) script with a few changes to speed up the transfer of information.

I wonder if there is any noticeable difference in the transmission of information between the current AllMovie.com (4) script and the transitional AllMovie.com (3) script, because one of these two will be in the future final version on Download page. (http://www.videodb.info/forum_en/index.php?action=down)
We welcome your feedback.

Script is the attached.
Title: Re: AllMovie.com_new movie script
Post by: UtNut on May 30, 2015, 06:15:20 pm
Yes, I'd say the the transmission is faster at import from AllMovie. Other than that the contents remain the same, which is great.

Thanks again.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 31, 2015, 09:32:27 am
Yes, I'd say the the transmission is faster at import from AllMovie. Other than that the contents remain the same, which is great.

Thanks again.

Thanks for your feedback.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on May 31, 2015, 12:02:46 pm
AllMovie.com_new script
v 0.1.2.5.


I fixed a lot of errors in the code for:

New Added:

In procedure ParseSearchResults is now added to the end of the list of search results is also a link to AllMovie search page for the current title of the movie you are looking for which you are currently looking information in their AllMovie database. It is now currently the only way that you can find the information for a particular movie if in the list of search results for a particular movie you did not find the title of this movie. According to the latest changes in the AllMovie web sites. it is now possible to search results to get a list with more than 20 hits - the title of films (including Source code page by the same number of titles of movies). If you want to find a movie title, you must
at AllMovie search page where you will at the bottom of search results then see the icon, which will then regenerate more movies titles. We'll see in the future what will be found to resolve some of the issues or problems.

There is now a new list of areas from which the transferred information. including normal and custom fields in the PVD database.

Code: [Select]
AllMovie data: PVD field: FN: Type/Comments:
-------------- --------- -- -------------
Actors ~ctActors~ 1, 3 credits (if GET_ACTORS true)
Alternate title ~Alternate title~ memo
AllMovie rating ~mfRating~ 1, 3 'Additional rating' named 'AllMovie.new' (if GET_RATING true)
OR ~AllMovie rating~ 2 rating
Amazon ~Amazon~ memo (link to Search on Amazon)
AMG ID ~AMG ID~ short text
Awards ~AllMovie Awards~ memo (link to AllMovie Awards tab)
Cast ~Cast~ memo
Crew ~Crew~ memo
Category ~Category.AllMovie~ multiselect list
—not to be confused with ~mfCategory~ (used for 'Themes')
Characteristics
~Moods~ 2 multiselect list (from 'Characteristics')
AND ~Mood links~ memo (hyperlinks to AllMovie mood pages
—if available in web archive
~Keywords~ 2 memo (from 'Characteristics')
~Attributes~ 2 multiselect list (from 'Characteristics')
Themes from 'Characteristics'
~mfCategory~ 1 standard multiselect list (if GET_THEMES true) (from 'Characteristics')
OR ~Themes~ 2 multiselect list (from 'Characteristics')
AND ~Themes links~ 2 memo (hyperlinks to AllMovie themes pages)
Country ~mfCountry~ 1 standard multiselect list
OR ~Country~ 2 multiselect list
Cover-art ~Poster~ 1, 3 standard (if GET_POSTER true)
Directed by ~ctDirectors~ 1 standard multiselect list
Flags ~Flags~ multiselect list
Genres ~mfGenre~ 1 standard multiselect list
OR ~Genres~ 2 multiselect list
AND ~Genre links~ memo (links to AllMovie Genre page)
MPAA rating ~MPAA rating~ short text
Produced by ~mfStudio~ 1 standard short text
OR ~Produced by~ 2 multiselect list
Related ~AllMovie Related~ memo (link to AllMovie Related tab)
Review ~Review~ memo
Release date ~Released~ short text (multiple dates)
//OR Released ~Released~ short //text (more common single date)
Releases ~mfFeatures~ 1 standard memo (link to AllMovie Releases tab)
Released by ~Released by~ short text

Run time ~mfDuration~ 1, 3 standard number (if GET_DURATION true)
OR ~Run time~ 2 number (minutes)
Synopsis ~mfDescription~ standard memo
—use PVD preference to save in ANY available memo field
Sub-Genres ~Sub-Genres~ multiselect list
OR ~Sub-Genre links~ memo (links to AllMovie page)
Title ~mfTitle~ 1 standard short text
OR ~Title~ 2 short text
Year ~mfYear~ 1 standard number (from AllMovie 'Title (Year)' heading)
OR ~Year~ 2 short string
Updated ~Updated~ long text
URL ~mfURL~ 1 standard memo
OR ~URL~ 2 memo

AllMovie data are once again available:

Keywords Keywords

AllMovie data no longer again available:

Released Released
//OR Released ~Released~ short //text (more common single date)

AllMovie data no longer available:

Color type Color type
From book Book
Set in Set in
Tones mfTags

And this one change:
Now transferred only full Release date information if there is such information on web pages, but not itself released the year for movie, than this possibility was until now prior to the current changes in the AllMovie web sites.

Notice:
The new version of the script is added to the
Download page. (http://www.videodb.info/forum_en/index.php?action=down)
Title: Re: AllMovie.com_new movie script
Post by: UtNut on June 02, 2015, 05:37:51 am
Works like a charm. Many thanks.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on June 02, 2015, 02:01:47 pm
Works like a charm. Many thanks.

Thank you for the very nice feedback.
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on October 16, 2015, 04:13:00 pm
Hello Ivek23,

Is there a way NOT to import year as a part of Title, just Title?

Thank you in advance.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on October 16, 2015, 06:06:23 pm
Hello Ivek23,

Is there a way NOT to import year as a part of Title, just Title?

Thank you in advance.

Why?
That's already in the script is done so that the Title-free year in the normal field as well as in the "Title" custom field.

Code: [Select]
//~mfTitle~ or ~Title~

 curPos := Pos('<title>', HTML) + Length('<title>');
 if Pos(') - ', HTML) > 0 then
endPos := PosFrom(') - ', HTML, curPos)-6
 else
endPos := PosFrom(' -  | ', HTML, curPos);
TmpStr1 := Copy(HTML, curPos, endPos - curPos);
AddFieldValue(mfTitle, TmpStr1);
AddFieldValue(mfOrigTitle, TmpStr1);
Title := Copy(HTML, curPos, endPos - curPos);
Title1 := Copy(HTML, curPos, endPos - curPos);

 if Pos(') - ', HTML) > 0 then
endPos := PosFrom(') - ', HTML, curPos)+1
 else
endPos := PosFrom(' -  | ', HTML, curPos);
TmpStr1 := Copy(HTML, curPos, endPos - curPos);
AddCustomFieldValueByName('Title', TmpStr1);

The year has also done the same way as Title.

Code: [Select]
// ~mfYear~ or ~Year~
 
 curPos := Pos('<span class="release-year">', HTML) + Length('<span class="release-year">');
 if Pos('</span>        </h2>', HTML) > 0 then
endPos := PosFrom('</span>        </h2>', HTML, curPos);
TmpStr2 := Copy(HTML, curPos, endPos - curPos);

  if TmpStr2 = '0' then
TmpStr2 := '';
TmpStr2 := StringReplace(TmpStr2, '(', '', True, True, True);
TmpStr2 := StringReplace(TmpStr2, ')', '', True, True, True);
AddFieldValue(mfYear, TmpStr2);
AddCustomFieldValueByName('Year', TmpStr2);

  if TmpStr2 = '' then
TmpStr2 := 'year unknown';
 LogMessage(' Parsing: ' + TmpStr1 + '(' + TmpStr2 + ')');

If this is not what we would like, then please give an example to make it easier to explain and help.
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on October 16, 2015, 07:06:25 pm
Thanks for fast reply, Ivek.

I don't want to import year as a part of title because I import year in a separate field,  but mostly because it's not the part of real title.

I use Custom field "Title" to import title from AllMovie.com (which is mostly in English, and I need it), and Standard field "Title" to import localized title from Imdb (Serbian, as you can see on the screenshot), and standard origtitle to import original title from Imdb.

I wouldn't like to import year to a Custom field "Title" from AllMovie.com.

Thank you in advance.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on October 16, 2015, 07:28:30 pm
Try like this:

AddCustomFieldValueByName('Title', TmpStr1 + '(' + TmpStr2 + ')');

This is how it should be in the script:
Code: [Select]
//~mfTitle~ or ~Title~

 curPos := Pos('<title>', HTML) + Length('<title>');
 if Pos(') - ', HTML) > 0 then
endPos := PosFrom(') - ', HTML, curPos)-6
 else
endPos := PosFrom(' -  | ', HTML, curPos);
TmpStr1 := Copy(HTML, curPos, endPos - curPos);
AddFieldValue(mfTitle, TmpStr1);
AddFieldValue(mfOrigTitle, TmpStr1);
Title := Copy(HTML, curPos, endPos - curPos);
Title1 := Copy(HTML, curPos, endPos - curPos);

 if Pos(') - ', HTML) > 0 then
endPos := PosFrom(') - ', HTML, curPos)+1
 else
endPos := PosFrom(' -  | ', HTML, curPos);
TmpStr1 := Copy(HTML, curPos, endPos - curPos);
//AddCustomFieldValueByName('Title', TmpStr1);
.
.
.
 // ~mfYear~ or ~Year~
 
 curPos := Pos('<span class="release-year">', HTML) + Length('<span class="release-year">');
 if Pos('</span>        </h2>', HTML) > 0 then
endPos := PosFrom('</span>        </h2>', HTML, curPos);
TmpStr2 := Copy(HTML, curPos, endPos - curPos);

  if TmpStr2 = '0' then
TmpStr2 := '';
TmpStr2 := StringReplace(TmpStr2, '(', '', True, True, True);
TmpStr2 := StringReplace(TmpStr2, ')', '', True, True, True);
AddFieldValue(mfYear, TmpStr2);
// AddCustomFieldValueByName('Year', TmpStr2);

  if TmpStr2 = '' then
TmpStr2 := 'year unknown';
 LogMessage(' Parsing: ' + TmpStr1 + '(' + TmpStr2 + ')');

AddCustomFieldValueByName('Title', TmpStr1 + '(' + TmpStr2 + ')');

I did not tested, but it should work.
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on October 16, 2015, 10:15:39 pm
Thanks, Ivek,

But now I get year two times, and I want without year at all, like in the second screenshot.

Thank you!

Quote
That's already in the script is done so that the Title-free year in the normal field as well as in the "Title" custom field.

It isn't in my case. When I import Title it imports title with year?!

In custom field "Title" it should be only "A Bittersweet Life", and not "A Bittersweet Life (2005)"
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on October 17, 2015, 06:34:26 am
OK, now I understand what and how the thing looked like. I'm sorry, last night I did not 100% of the stuff because I night vision a little teases (I see worse because the eyes are too tired).

OK, now could be the right solution:

not this one
Hello Ivek23,

Is there a way NOT to import year as a part of Title, just Title?

Thank you in advance.

Why?
That's already in the script is done so that the Title-free year in the normal field as well as in the "Title" custom field.

Code: [Select]
//~mfTitle~ or ~Title~

 curPos := Pos('<title>', HTML) + Length('<title>');
 if Pos(') - ', HTML) > 0 then
endPos := PosFrom(') - ', HTML, curPos)-6
 else
endPos := PosFrom(' -  | ', HTML, curPos);
TmpStr1 := Copy(HTML, curPos, endPos - curPos);
AddFieldValue(mfTitle, TmpStr1);
AddFieldValue(mfOrigTitle, TmpStr1);
Title := Copy(HTML, curPos, endPos - curPos);
Title1 := Copy(HTML, curPos, endPos - curPos);

 if Pos(') - ', HTML) > 0 then
endPos := PosFrom(') - ', HTML, curPos)+1
 else
endPos := PosFrom(' -  | ', HTML, curPos);
TmpStr1 := Copy(HTML, curPos, endPos - curPos);
AddCustomFieldValueByName('Title', TmpStr1);

The year has also done the same way as Title.

Code: [Select]
// ~mfYear~ or ~Year~
 
 curPos := Pos('<span class="release-year">', HTML) + Length('<span class="release-year">');
 if Pos('</span>        </h2>', HTML) > 0 then
endPos := PosFrom('</span>        </h2>', HTML, curPos);
TmpStr2 := Copy(HTML, curPos, endPos - curPos);

  if TmpStr2 = '0' then
TmpStr2 := '';
TmpStr2 := StringReplace(TmpStr2, '(', '', True, True, True);
TmpStr2 := StringReplace(TmpStr2, ')', '', True, True, True);
AddFieldValue(mfYear, TmpStr2);
AddCustomFieldValueByName('Year', TmpStr2);

  if TmpStr2 = '' then
TmpStr2 := 'year unknown';
 LogMessage(' Parsing: ' + TmpStr1 + '(' + TmpStr2 + ')');

If this is not what we would like, then please give an example to make it easier to explain and help.

even this does not
Try like this:

AddCustomFieldValueByName('Title', TmpStr1 + '(' + TmpStr2 + ')');

This is how it should be in the script:
Code: [Select]
//~mfTitle~ or ~Title~

 curPos := Pos('<title>', HTML) + Length('<title>');
 if Pos(') - ', HTML) > 0 then
endPos := PosFrom(') - ', HTML, curPos)-6
 else
endPos := PosFrom(' -  | ', HTML, curPos);
TmpStr1 := Copy(HTML, curPos, endPos - curPos);
AddFieldValue(mfTitle, TmpStr1);
AddFieldValue(mfOrigTitle, TmpStr1);
Title := Copy(HTML, curPos, endPos - curPos);
Title1 := Copy(HTML, curPos, endPos - curPos);

 if Pos(') - ', HTML) > 0 then
endPos := PosFrom(') - ', HTML, curPos)+1
 else
endPos := PosFrom(' -  | ', HTML, curPos);
TmpStr1 := Copy(HTML, curPos, endPos - curPos);
//AddCustomFieldValueByName('Title', TmpStr1);
.
.
.
 // ~mfYear~ or ~Year~
 
 curPos := Pos('<span class="release-year">', HTML) + Length('<span class="release-year">');
 if Pos('</span>        </h2>', HTML) > 0 then
endPos := PosFrom('</span>        </h2>', HTML, curPos);
TmpStr2 := Copy(HTML, curPos, endPos - curPos);

  if TmpStr2 = '0' then
TmpStr2 := '';
TmpStr2 := StringReplace(TmpStr2, '(', '', True, True, True);
TmpStr2 := StringReplace(TmpStr2, ')', '', True, True, True);
AddFieldValue(mfYear, TmpStr2);
// AddCustomFieldValueByName('Year', TmpStr2);

  if TmpStr2 = '' then
TmpStr2 := 'year unknown';
 LogMessage(' Parsing: ' + TmpStr1 + '(' + TmpStr2 + ')');

AddCustomFieldValueByName('Title', TmpStr1 + '(' + TmpStr2 + ')');

I did not tested, but it should work.

but this should however be fine
Code: [Select]
//~mfTitle~ or ~Title~

 curPos := Pos('<title>', HTML) + Length('<title>');
 if Pos(') - ', HTML) > 0 then
endPos := PosFrom(') - ', HTML, curPos)-6
 else
endPos := PosFrom(' -  | ', HTML, curPos);
TmpStr1 := Copy(HTML, curPos, endPos - curPos);
AddFieldValue(mfTitle, TmpStr1);
AddFieldValue(mfOrigTitle, TmpStr1);
Title := Copy(HTML, curPos, endPos - curPos);
Title1 := Copy(HTML, curPos, endPos - curPos);

// if Pos(') - ', HTML) > 0 then
// endPos := PosFrom(') - ', HTML, curPos)+1
// else
// endPos := PosFrom(' -  | ', HTML, curPos);
// TmpStr1 := Copy(HTML, curPos, endPos - curPos);
AddCustomFieldValueByName('Title', TmpStr1);

This is how it should be in the script:
Try like this:

AddCustomFieldValueByName('Title', TmpStr1 + '(' + TmpStr2 + ')');

This is how it should be in the script:
Code: [Select]
//~mfTitle~ or ~Title~

 curPos := Pos('<title>', HTML) + Length('<title>');
 if Pos(') - ', HTML) > 0 then
endPos := PosFrom(') - ', HTML, curPos)-6
 else
endPos := PosFrom(' -  | ', HTML, curPos);
TmpStr1 := Copy(HTML, curPos, endPos - curPos);
AddFieldValue(mfTitle, TmpStr1);
AddFieldValue(mfOrigTitle, TmpStr1);
Title := Copy(HTML, curPos, endPos - curPos);
Title1 := Copy(HTML, curPos, endPos - curPos);

// if Pos(') - ', HTML) > 0 then
// endPos := PosFrom(') - ', HTML, curPos)+1
// else
// endPos := PosFrom(' -  | ', HTML, curPos);
// TmpStr1 := Copy(HTML, curPos, endPos - curPos);
AddCustomFieldValueByName('Title', TmpStr1);
.
.
.
 // ~mfYear~ or ~Year~
 
 curPos := Pos('<span class="release-year">', HTML) + Length('<span class="release-year">');
 if Pos('</span>        </h2>', HTML) > 0 then
endPos := PosFrom('</span>        </h2>', HTML, curPos);
TmpStr2 := Copy(HTML, curPos, endPos - curPos);

  if TmpStr2 = '0' then
TmpStr2 := '';
TmpStr2 := StringReplace(TmpStr2, '(', '', True, True, True);
TmpStr2 := StringReplace(TmpStr2, ')', '', True, True, True);
AddFieldValue(mfYear, TmpStr2);
// AddCustomFieldValueByName('Year', TmpStr2);

  if TmpStr2 = '' then
TmpStr2 := 'year unknown';
 LogMessage(' Parsing: ' + TmpStr1 + '(' + TmpStr2 + ')');
Title: Re: AllMovie.com_new movie script
Post by: afrocuban on October 17, 2015, 10:18:55 am
Ivek,

Great tip and work as usual! Thank you so much for being there for us!  :D

Wish you all the best.

Note: This is to relate to this forum topic (http://www.videodb.info/forum_en/index.php/topic,3334.0.html), if someone is interested in with it.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on October 17, 2015, 11:23:16 am
Ivek,

Great tip and work as usual! Thank you so much for being there for us!  :D

Wish you all the best.

Note: This is to relate to this forum topic (http://www.videodb.info/forum_en/index.php/topic,3334.0.html), if someone is interested in with it.

Thank you, good to hear that now everything is fine and that it works.
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on November 18, 2017, 09:05:36 am
Important news:

AllMovie.com_new script don't work anymore and AllMovie.com is the next Web site that is passed to a secure https:// connection.

AllMovie.com works with AllMovie.com_new_HTTPS script version 1.1.2.6 (http://www.videodb.info/forum_en/index.php?action=dlattach;topic=4109.0;attach=6543) or  AllMovie.com_new_HTTPS script version 1.1.2.5 (http://www.videodb.info/forum_en/index.php?action=dlattach;topic=4109.0;attach=6541) again.

For more information, read this topic Proxomitron - next https solution for PVD (http://www.videodb.info/forum_en/index.php?topic=4083.0) in the Development section and Allmovie.com https (http://www.videodb.info/forum_en/index.php/topic,4109.msg20181.html#msg20181) topic in the
Support section

For all guests:

You can find a link to download the script in AllMovie.com_new_HTTPS Movie Links topic. (http://www.videodb.info/forum_en/index.php/topic,4110.msg20182.html#msg20182)
Title: Re: AllMovie.com_new movie script
Post by: Ivek23 on November 27, 2023, 07:13:49 pm
Here is the url link to the new AllMovie.com HTTPS script beta for PVD MOD versions.

http://www.videodb.info/forum_en/index.php/topic,4109.msg21882.html#msg21882