I want to inform all italian users that you can find the updated version of the italian scripts at this address:
http://forum.doom9.it/viewtopic.php?t=2 ... ie&start=0
Please note that the script that are actually used in amc for "Filmup.it" and "Cinematografo.it" works parctially because the original sites was changed while the improved versions at the address above works perfectly.
I hope that these versions will be enclosed in the next release of AMC
new italian scripts update
Re: new italian scripts update
Sure.Anonymous wrote: I hope that these versions will be enclosed in the next release of AMC
I guess that the scripts that I have to include are these two :
http://forum.doom9.it/viewtopic.php?p=28155#28155
http://forum.doom9.it/viewtopic.php?p=28581#28581
Yes, i confirm that these are the updated scripts to insert in AMC.
The script for "Cinematografo.it" replace the actual script in AMC
that doesn't works anymore because the site has changed.
The script for "Filmup.it" is more powerful respect to the actual script in AMC because extract from the site the comments and other informations too.
The script for "Cinematografo.it" replace the actual script in AMC
that doesn't works anymore because the site has changed.
The script for "Filmup.it" is more powerful respect to the actual script in AMC because extract from the site the comments and other informations too.
I have done another modifies to the script of Cinematografo.It modifying the selection of Search. The old script sought all the titles of film that contained "the string" in the title. Often, when a short title was sought (example LEON), the search could give many results. The change allows to seek Only the Title that has The String instead. If it interests you I copy you the modified Script.
Bye bye. Destroyer76
Ho fatto un'altra modifica allo script di Cinematografo.it, modificando la selezione di Ricerca. Il vecchio script ricercava tutti i titoli di film che contenevano "la stringa" nel titolo. Spesso, quando si ricercava un titolo corto (esempio LEON), la ricerca poteva dare molti risultati. La modifica invece permette di ricercare SOLO il Titolo che ha quella stringa. Se vi interessa vi copio lo Script modificato.
Ciao ciao. Destroyer76
Bye bye. Destroyer76
Ho fatto un'altra modifica allo script di Cinematografo.it, modificando la selezione di Ricerca. Il vecchio script ricercava tutti i titoli di film che contenevano "la stringa" nel titolo. Spesso, quando si ricercava un titolo corto (esempio LEON), la ricerca poteva dare molti risultati. La modifica invece permette di ricercare SOLO il Titolo che ha quella stringa. Se vi interessa vi copio lo Script modificato.
Ciao ciao. Destroyer76
Eccoti lo script modificato....
Spero ti possa essere utile.
Ciao ciao.
Spero ti possa essere utile.
Ciao ciao.
Code: Select all
// GETINFO SCRIPTING
// Cinematografo.it
(***************************************************
* Movie importation script for: *
* Cinematografo.it, http://www.cinematografo.it *
* *
* (c) 2003 Andrea Cristaudo achris@tiscalinet.it *
* *
* For use with Ant Movie Catalog 3.4.1 *
* www.ant.be.tf/moviecatalog ··· www.buypin.com *
* *
* The source code of the script can be used in *
* another program only if full credits to *
* script author and a link to Ant Movie Catalog *
* website are given in the About box or in *
* the documentation of the program *
* *
* *
* 30/10/2003 Modificato da Zandal per cambio *
* gestione indirizzi pagine *
* su Cinematografo.it *
* *
* 29/12/2003 Modificato da Destroyer76 per *
* eseguire la la ricerca del Titolo *
* su una STRINGA IDENTICA a quella *
* Inserita, per evitare di avere molti *
* risultati quando la STRINGA di *
* ricerca è contenuto in molti film. *
* *
* *
***************************************************)
program Cinematografo;
var
MovieName: string;
TheMovieAddress: string;
function RemoveTabs(Pattern: string): string;
begin
repeat
Delete(Pattern, 1, 1);
until ord(copy(Pattern, 1, 1)) <> 9;
result := Pattern;
end;
function Space2html(Url: string): string;
var
Temp : string;
SpacePos : Integer;
begin
repeat
SpacePos := pos(' ', Url);
if SpacePos <> 0 then
begin
Temp := copy(Url, 1, SpacePos -1);
Delete(Url, 1, SpacePos);
Temp := Temp + '%20' + Url;
Url := Temp;
end;
until pos(' ', Url) = 0;
result := Url;
end;
function FillInput(Page: TStringList; LineNr: Integer; Salto: Integer; Field: Integer): Integer;
var
Line: string;
begin
LineNr := LineNr + Salto;
Line := StringReplace(Page.GetString(LineNr), '<BR>', #13#10);
HTMLRemoveTags(Line);
HTMLDecode(Line);
Line := Trim(RemoveTabs(Line));
if Field = fieldActors then
Line := StringReplace(Line, ' ', ' : ');
Line := StringReplace(Line, ' ', ' ');
SetField(Field, Line);
Result := LineNr;
end;
function FindLine(Pattern: string; List: TStringList; StartAt: Integer): Integer;
var
i: Integer;
begin
result := -1;
if StartAt < 0 then
StartAt := 0;
for i := StartAt to List.Count-1 do
if Pos(Pattern, List.GetString(i)) <> 0 then
begin
result := i;
Break;
end;
end;
procedure AnalyzePage(Address: string);
var
Page: TStringList;
LineNr: integer;
BeginPos: integer;
begin
Page := TStringList.Create;
Page.Text := GetPage(Address);
LineNr := FindLine('DELLA RICERCA', Page, 0);
if LineNr = -1 then
begin
LineNr := FindLine('<b>La vostra richiesta non trova risposta nell''archivio.</b>', Page, 0);
if LineNr = -1 then
begin
SetField(fieldURL, Address);
AnalyzeMoviePage(Page);
end
else
begin
ShowMessage('Nessun film trovato');
end;
end
else
begin
PickTreeClear;
// input ('test','test',page)
AddMoviesTitles(Page);
if TheMovieAddress='' then
begin
if PickTreeExec(Address) then
begin
SetField(fieldURL, Address);
Page.Text := GetPage(Address);
AnalyzeMoviePage(Page);
end;
end
else
begin
SetField(fieldURL, TheMovieAddress);
Page.Text := GetPage(TheMovieAddress);
AnalyzeMoviePage(Page);
end;
end;
Page.Free;
end;
procedure AnalyzeMoviePage(Page: TStringList);
var
Fine: Integer;
Line: string;
LineNr: Integer;
BeginPos, EndPos: Integer;
Field: integer;
begin
Fine := 0;
// LineNr := FindLine('<strong>Titolo Film</strong>', Page, 0);
LineNr := FindLine('<font color="#ffffff">Titolo Film</font>', Page, 0);
if LineNr > -1 then
begin
//Translated Title
LineNr := LineNr + 5;
Line := Page.GetString(LineNr);
HTMLRemoveTags(Line);
Line := RemoveTabs(Line);
SetField(fieldTranslatedTitle, Line);
LineNr := LineNr + 3;
Line := Page.GetString(LineNr);
if pos('<img border="0" src="', Line) <> 0 then
begin
BeginPos := pos('<img border="0" src="', Line);
Delete(Line, 1, BeginPos + 20);
EndPos := pos('" ', Line);
Line := copy(Line, 1, EndPos - 1);
Line := StringReplace(Line, ' ', '');
Line := 'http://www.cinematografo.it/bdcm/' + Line;
Line := Space2html(Line);
GetPicture(Line, False);
end
repeat
LineNr := LineNr + 1;
Line := Page.GetString(LineNr);
if pos('<font color="#ffffff">Anno</font>', Line) <> 0 then
LineNr := FillInput(Page, LineNr, 3, fieldYear)
else if pos('<font color="#ffffff">Titolo originale</font>', Line) <> 0 then
LineNr := FillInput(Page, LineNr, 3, fieldOriginalTitle)
else if pos('<font color="#ffffff">Durata</font>', Line) <> 0 then
LineNr := FillInput(Page, LineNr, 3, fieldLength)
else if pos('<font color="#ffffff">Origine</font>', Line) <> 0 then
LineNr := FillInput(Page, LineNr, 3, fieldCountry)
else if pos('<font color="#ffffff">Genere</font>', Line) <> 0 then
LineNr := FillInput(Page, LineNr, 3, fieldCategory)
else if pos('<font color="#ffffff">Produzione</font>', Line) <> 0 then
LineNr := FillInput(Page, LineNr, 3, fieldProducer)
else if pos('<font color="#ffffff">Regia</font>', Line) <> 0 then
LineNr := FillInput(Page, LineNr, 3, fieldDirector)
else if pos('<font color="#ffffff">Trama</font>', Line) <> 0 then
LineNr := FillInput(Page, LineNr, 3, fieldDescription)
else if pos('<font color="#ffffff">Critica</font>', Line) <> 0 then
LineNr := FillInput(Page, LineNr, 3, fieldComments)
else if pos('<font color="#ffffff">Attori</font>', Line) <> 0 then
LineNr := FillInput(Page, LineNr, 3, fieldActors)
else if pos('<img align="right" border="0"', Line) <> 0 then
begin
BeginPos := pos('<img align="right" border="0" src="', Line);
Delete(Line, 1, BeginPos + 35);
EndPos := pos('">', Line);
Line := copy(Line, 1, EndPos - 1);
Line := 'http://www.cinematografo.it/' + Line;
Line := Space2html(Line);
GetPicture(Line, False);
end
else if pos('</table>', Line) <> 0 then
Fine := 1;
until Fine = 1;
end;
DisplayResults;
end;
procedure AddMoviesTitles(Page: TStringList);
var
LineNr: Integer;
Line: string;
MovieTitle, MovieAddress: string;
BeginPos, EndPos: Integer;
begin
TheMovieAddress := '*';
LineNr := 0;
// LineNr := FindLine('<a href="/dati/scheda.asp?sch=',Page,LineNr);
LineNr := FindLine('<a href="bancadati_scheda.asp?sch=',Page,LineNr);
while LineNr > -1 do
begin
Line := Page.GetString(LineNr);
BeginPos := pos('<a href="',Line)+9;
Delete(Line, 1, BeginPos-1);
BeginPos := 1; //pos('<a href="',Line)+9;
EndPos := pos('">',Line);
MovieAddress := 'http://www.cinematografo.it' + '/bdcm/' + copy(Line,BeginPos,EndPos-BeginPos);
LineNr := LineNr + 1;
Line := Page.GetString(LineNr);
MovieTitle := Line;
HTMLRemoveTags(MovieTitle);
HTMLDecode(MovieTitle);
MovieTitle := RemoveTabs(MovieTitle);
// LineNr := LineNr + 5;
// Line := Page.GetString(LineNr);
// input ('test1','testfilm',Line);
// HTMLRemoveTags(Line);
// input ('test2','testfilm',Line);
// Line := RemoveTabs(Line);
// input ('test3','testfilm',Line);
// MovieTitle := MovieTitle + ' (' + Line + ')';
PickTreeAdd(MovieTitle, MovieAddress);
LineNr := FindLine('<a href="bancadati_scheda.asp?sch=',Page,LineNr+1);
// LineNr := FindLine('<a href="/dati/scheda.asp?sch=',Page,LineNr+1);
if TheMovieAddress='*' then
TheMovieAddress := MovieAddress
else
TheMovieAddress := '';
end;
if TheMovieAddress='*' then TheMovieAddress := '';
end;
Var
TempVar: String;
begin
if CheckVersion(3,4,1) then
begin
MovieName := GetField(fieldOriginalTitle);
if MovieName = '' then
MovieName := GetField(fieldTranslatedTitle);
if Input('Cinematografo.it', 'Enter the title of the movie:', MovieName) then
begin
// TempVar :='http://www.cinematografo.it/bdcm/bancadati_query.asp?fi='+UrlEncode(MovieName)+'&R1=TI&x=27&y=16';
TempVar :='http://www.cinematografo.it/bdcm/bancadati_qrysrcfld.asp?tifilmopt=UGUALE&tifilm='+UrlEncode(MovieName)+'&R1=TI&x=27&y=16';
// AnalyzePage('http://www.cinematografo.it/bdcm/bancadati_query.asp?fi='+UrlEncode(MovieName)+'&R1=TI&x=27&y=16') //'&submit1=++Cerca++');
analyzepage(TempVar)
end;
end else
ShowMessage('This script requires a newer version of Ant Movie Catalog (at least the version 3.4.1)');
end.
Please note that the script for "35mm.it" doesn't works anymore and crashes Amc.
I have noted too that the script for "Cinematografo.it" now works partially.
There is someone that can update these script and post them here?
Thanks in advance.
Volevo avvisare the lo script per 35mm. non funziona più e blocca Amc.
Ho anche notato che lo script per Cinematografo ora funziona parzialmente.
C'è qualcuno che può aggiornare questi scripts e postarli qui?
Grazie in anticipo.
I have noted too that the script for "Cinematografo.it" now works partially.
There is someone that can update these script and post them here?
Thanks in advance.
Volevo avvisare the lo script per 35mm. non funziona più e blocca Amc.
Ho anche notato che lo script per Cinematografo ora funziona parzialmente.
C'è qualcuno che può aggiornare questi scripts e postarli qui?
Grazie in anticipo.
It does not crash, it is only an endless loop that can be stopped by clicking the "Stop" button of the toolbar.Anonymous wrote:Please note that the script for "35mm.it" doesn't works anymore and crashes Amc.
For the moment I do not have time to correct these scripts, so if somebody else can do it, it would be nice