[ES] Script en español para FilmAffinity

If you made a script you can offer it to the others here, or ask help to improve it. You can also report here bugs & problems with existing scripts.
aviloria

[ES] Script en español para FilmAffinity

Post by aviloria »

Hola a todos,

Ante las nuevas modificaciones que se han llevado a cabo en la página de FilmAffinity, aqui os traigo el nuevo script...

Espero que con ello se resuelvan todos los problemas...
Un saludo
aviloria

Code: Select all

(***************************************************

Ant Movie Catalog importation script
www.antp.be/software/moviecatalog/

[Infos]
Authors=aviloria  (aviloria@yahoo.com)
Title=FilmAffinity (ES)
Description=Movie importation script for FilmAffinity Spain
Site=http://www.filmaffinity.com
Language=ES
Version=1.0
Requires=3.5.0
Comments=Updated by folgui to: |  - Separate import of Category and Description |  - Search only by title to improve speed|
License=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.|
GetInfo=1

[Options]

***************************************************)

program FilmAffinity;

const
  SearchBaseURL = 'http://www.filmaffinity.com/es/res.php?stext=';
  SearchPostFix = '&stype=tit'; 
  BaseURL1 = 'http://www.filmaffinity.com/es/';
  BaseURL2 = 'http://www.filmaffinity.com';

var
  MovieName: string;
  MovieURL: string;
//------------------------------------------------------------------------------------

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;
//------------------------------------------------------------------------------------

function TextBetween(var S: string; StartTag: string; EndTag: string): string;
var
  InitialPos: Integer;
begin
  InitialPos := Pos(StartTag, S);
  Delete(S, 1, InitialPos + Length(StartTag) - 1);
  InitialPos := Pos(EndTag, S);
  result := copy(S, 1, InitialPos - 1);
  Delete(S, 1, InitialPos + 1);
end;
//------------------------------------------------------------------------------------

procedure AnalyzePage(Address: string);
var
  Page: TStringList;
  LineNr: Integer;
  Line: string;
  MovieTitle, MovieAddress: string;

begin
  Page := TStringList.Create;
  Page.Text := GetPage(Address);
  if Pos('<title>FilmAffinity', Page.Text) = 0 then
  begin
    ShowMessage('No se ha podido establecer la conexion.');
  end else
  begin
    LineNr := FindLine('<td class="tt1" align="center">Resultados por Título</td>', Page, 0);
    LineNr := LineNr + 6;
    Line := Page.GetString(LineNr);
    if Pos ('No se han encontrado coincidencias', Line) <> 0 then
    begin
      ShowMessage('No se han encontrado resultados para "' + MovieName + '"');
    end else
    begin
      PickTreeClear;
      Line := TextBetween (Line, '<b>', '</b>');
      PickTreeAdd('Encontrados ' + Line + ' resultados para "' + MovieName + '"', '');

      LineNr := LineNr + 9;
      Line := Page.GetString(LineNr);
      repeat
        MovieTitle := TextBetween (Line, '<span class="ntext">', '</span>');
        HTMLDecode(MovieTitle);
        LineNr := LineNr + 3;
        Line := Page.GetString(LineNr);
        MovieAddress := TextBetween (Line, '.href = ''', ''';</script>');
        PickTreeAdd(MovieTitle, BaseURL1 + MovieAddress);
        LineNr := LineNr + 2;
        Line := Page.GetString(LineNr);
      until Pos('</ol>', Line) > 0;

      if PickTreeExec(Address) then
        AnalyzeMoviePage(Address);
    end;
  end;
  Page.Free;
end;
//------------------------------------------------------------------------------------

procedure AnalyzeMoviePage(Address: string);
var
  Page: TStringList;
  LineNr, aux: Integer;
  Line: string;
  Item: string;
  Comments: string;
  Actors: string;
  Directors: string;
  Description: string;

begin
  Comments := '';
  Actors := '';
  Description := '';

  // URL
  SetField(fieldURL, Address);

  Page := TStringList.Create;
  Page.Text := GetPage(Address);

  // Translated Title
  LineNr := FindLine('<td align="center" class="tt1">', Page, 0);
  Line := Page.GetString(LineNr);
  Item := TextBetween (Line, '<td align="center" class="tt1">', ' <img src=');
  HTMLDecode(Item);
  SetField(fieldTranslatedTitle, Trim (Item));

  LineNr := LineNr + 8;
  Line := Page.GetString(LineNr);

  // Original Title
  if Pos ('TITULO ORIGINAL', Line) > 0 then
  begin
    LineNr := LineNr + 1;
    Line := Page.GetString(LineNr);
    Item := TextBetween (Line, '<td class="ntext">', '</td>');
    HTMLDecode(Item);
    SetField(fieldOriginalTitle, Trim (Item));
    LineNr := LineNr + 1;
    Line := Page.GetString(LineNr);
  end;

  // Picture
  if Pos ('owned by Studio', Line) > 0 then
  begin
    Item := TextBetween (Line, '<img src="', '" >');
    GetPicture (BaseURL2 + Item);
    LineNr := LineNr + 3;
    Line := Page.GetString(LineNr);
  end;

  // Year
  if Pos ('AÑO', Line) > 0 then
  begin
    LineNr := LineNr + 1;
    Line := Page.GetString(LineNr);
    Item := TextBetween (Line, '<td class="ntext">', '</td>');
    HTMLDecode(Item);
    SetField(fieldYear, Trim (Item));
    LineNr := LineNr + 3;
    Line := Page.GetString(LineNr);
  end;

  // Length
  if Pos ('DURACIÓN', Line) > 0 then
  begin
    LineNr := LineNr + 1;
    Line := Page.GetString(LineNr);
    Item := TextBetween (Line, '<td class="ntext">', '</td>');
    HTMLDecode(Item);
    aux := Pos (' min', Item);
    if aux > 0 then
      Delete (Item, aux, aux + 3);
    SetField(fieldLength, Trim (Item));
    LineNr := LineNr + 3;
    Line := Page.GetString(LineNr);
  end;

  // Country
  if Pos ('PAÍS', Line) > 0 then
  begin
    LineNr := LineNr + 1;
    Line := Page.GetString(LineNr);
    Item := TextBetween (Line, 'alt="', '">');
    HTMLDecode(Item);
    SetField(fieldCountry, Trim (Item));
    LineNr := LineNr + 3;
    Line := Page.GetString(LineNr);
  end;

  // Director
  if Pos ('DIRECTOR', Line) > 0 then
  begin
    LineNr := LineNr + 1;
    Line := Page.GetString(LineNr);
    Directors := '';
    while Pos ('&stype=dir">', Line) > 0 do
    begin
      Item := TextBetween (Line, '&stype=dir">', '</a>');
      HTMLDecode(Item);
      if Directors = '' then
        Directors := Item
      else
        Directors := Directors + ', ' + Item;
    end;
    SetField(fieldDirector, Trim (Directors));
    LineNr := LineNr + 3;
    Line := Page.GetString(LineNr);
  end;

  // Script writer
  if Pos ('GUIÓN', Line) > 0 then
  begin
    LineNr := LineNr + 1;
    Line := Page.GetString(LineNr);
    Item := TextBetween (Line, '<td class="ntext">', '</td>');
    Comments := Comments + 'Guión: ' + Item + #13#10;
    LineNr := LineNr + 3;
    Line := Page.GetString(LineNr);
  end;

  // Musician
  if Pos ('MUSICA', Line) > 0 then
  begin
    LineNr := LineNr + 1;
    Line := Page.GetString(LineNr);
    Item := TextBetween (Line, '<td class="ntext" >', '</td>');
    Comments := Comments + 'Música: ' + Item + #13#10;
    LineNr := LineNr + 3;
    Line := Page.GetString(LineNr);
  end;

  // Photography
  if Pos ('FOTOGRAFÍA', Line) > 0 then
  begin
    LineNr := LineNr + 1;
    Line := Page.GetString(LineNr);
    Item := TextBetween (Line, '<td class="ntext" >', '</td>');
    Comments := Comments + 'Fotografía: ' + Item + #13#10;
    LineNr := LineNr + 3;
    Line := Page.GetString(LineNr);
  end;

  // Actors
  if Pos ('REPARTO', Line) > 0 then
  begin
    LineNr := LineNr + 1;
    Line := Page.GetString(LineNr);
    Actors := Actors + TextBetween (Line, '&stype=rep">', '</a>') + #13#10;
    while Pos ('&stype=rep"> ', Line) > 0 do
      Actors := Actors + TextBetween (Line, '&stype=rep"> ', '</a>') + #13#10;
    LineNr := LineNr + 3;
    Line := Page.GetString(LineNr);
  end;

  // Productor
  if Pos ('PRODUCTORA', Line) > 0 then
  begin
    LineNr := LineNr + 1;
    Line := Page.GetString(LineNr);
    Item := TextBetween (Line, '<td class="ntext" colspan="2">', '</td>');
    HTMLDecode(Item);
    SetField(fieldProducer, Trim (Item));
    LineNr := LineNr + 3;
    Line := Page.GetString(LineNr);
  end;
   
  // Genere & Critic
  if Pos ('GÉNERO Y CRÍTICA', Line) > 0 then
  begin
    Line := Copy (Page.Text, 1, Length (Page.Text));
    Line := StringReplace(Line, '<br />', #13#10);
    Line := TextBetween (Line, 'GÉNERO Y CRÍTICA', '</tr>');
    Item := TextBetween (Line, '<td class="ntext" colspan="2">', '/ SINOPSIS:');
    HTMLDecode(Item);
    SetField(fieldCategory, Trim(Item));
    Description := TextBetween (Line, '/ SINOPSIS:', '</td>');
    LineNr := FindLine('WEB OFICIAL', Page, LineNr);
    Line := Page.GetString(LineNr);
  end;

  // Official Webpage
  if Pos ('WEB OFICIAL', Line) > 0 then
  begin
    LineNr := LineNr + 1;
    Line := Page.GetString(LineNr);
    Comments := Comments + 'Web oficial: ' + TextBetween (Line, '<a href="', '" target="_blank">') + #13#10;
    LineNr := LineNr + 3;
    Line := Page.GetString(LineNr);
  end;

  // Rating
  if Pos ('PUNTUACIÓN MEDIA', Line) > 0 then
  begin
    LineNr := LineNr + 1;
    Line := Page.GetString(LineNr);
    Item := TextBetween (Line, '<b>', '</b>');
    HTMLDecode(Item);
    if Length(Item) = 3 then
//    begin
//      Item := IntToStr(Round(StrToInt(StrGet(Item, 1), 0) + (StrToInt(StrGet(Item, 3), 0) / 10)));
//    end else
//    begin
//      Item := IntToStr(Round(StrToInt(StrGet(Item, 1), 0)));
//    end;
    SetField(fieldRating, Item);
    LineNr := LineNr + 3;
    Line := Page.GetString(LineNr);
  end;

  HTMLDecode(Comments);
  SetField(fieldComments, Comments);
  HTMLDecode(Actors);
  SetField(fieldActors, Actors);
  HTMLDecode(Description);
  SetField(fieldDescription, Description);
end;
//------------------------------------------------------------------------------------
//------------------------------------------------------------------------------------

begin
  if CheckVersion(3,5,0) then
  begin
    MovieName := GetField(fieldOriginalTitle);
    if MovieName = '' then
      MovieName := GetField(fieldTranslatedTitle);
    if Input('Importar de FilmAffinity', 'Introduzca el titulo de la pelicula:', MovieName) then
    begin
      AnalyzePage(SearchBaseURL + UrlEncode(MovieName) + SearchPostfix);
    end;
  end
  else
    ShowMessage('Este script requiere una version mas reciente de Ant Movie Catalog (por lo menos la version 3.5.0)');
end. 
folgui
Posts: 113
Joined: 2003-02-04 19:15:03
Location: Madrid, Spain

Post by folgui »

:grinking:

Thank you very much. I usually don't use this script and didn't know about that changes, but it's nice to see it updated.

Only one suggestion...can you edit the above code and put in version something different since que old one was 1.0 , now it could be 1.1 o similar. It's better to let the users recognise the latest version.

Regards, folgui.
Last edited by folgui on 2005-05-16 18:09:09, edited 1 time in total.
Juanra
Posts: 9
Joined: 2004-02-25 19:23:49

Funciona

Post by Juanra »

Español: Lo he probado y parece que ya funciona bien. Con la versión anterior se quedaba colgado el AMC al ejecutar el script.

Como dice folgui, cambia la versión a 1.1

Saludos

English: I've tested it and seems to work fine now. In previous version, AMC got hung when executing the script.

As folgui says, change the version number to 1.1

Regards
Guest

Post by Guest »

Hola, acabo de bajarme el AMC 3.5.0.1, no sé muy bien que tengo que hacer para que me funcione el script de fimaffinity, de momento he copiado el code que has puesto ahí arriba en el editor del script pero no me funciona, me sale siempre el error :

403 forbbiden.

No sé si estoy haciendo algo mal.

Gracias
javilp

Post by javilp »

A mi me pasa lo mismo. Hace un par de dias probe el script e iba de maravilla, y ahora HTTP/ 1.1 403 Forbidden. Me parece que ocurre como en otra pagina, ahora mismo no recuerdo cual, que he leido en el foro que prohibe al AMC hacer busquedas.

ENGLISH: I can't download any information with this script. Two days ago, I tested the script and worked well. Now I receive the return message: "HTTP/1.1 Forbidden". I think it could be like another spanish site: now I don't remember what site is, it forbides the access to AMC and to do any search with the script.
aviloria

Solucion al error Forbiden HTTP 1.1/403

Post by aviloria »

Hola a todos,

El problema que os está dando al ejecutar el script de FilmAffinity.com se debe a un cambio en la página.

Actualmente están probando la versión beta de su nueva web, y por eso genera este problema.

He modificado el script y espero que ahora podais utilizarlo.
Un saludo

-----------------------------------------------------------------------------
<english>
Hi,
The current problem with the FilmAffinity.com script cames from a change in the web-page.

Now they are testing the new release (beta version) of the web-page. That is is the problem.

I have update the script and I wish you can use it right now.

Code: Select all

(***************************************************

Ant Movie Catalog importation script
www.antp.be/software/moviecatalog/

[Infos]
Authors=aviloria  (aviloria@yahoo.com)
Title=FilmAffinity (ES)
Description=Movie importation script for FilmAffinity Spain
Site=http://www.filmaffinity.com
Language=ES
Version=1.2
Requires=3.5.0
Comments=Updated to the new beta version of the page | Previous version is unsupported.
License=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.|
GetInfo=1

[Options]

***************************************************)

program FilmAffinity;

const
  SearchBaseURL = 'http://new.filmaffinity.com/es/res.php?stext=';
  SearchPostFix = '&stype=tit';
  BaseURL1 = 'http://new.filmaffinity.com';

var
  MovieName: string;
  MovieURL: string;
//------------------------------------------------------------------------------------

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;
//------------------------------------------------------------------------------------

function TextBetween(var S: string; StartTag: string; EndTag: string): string;
var
  InitialPos: Integer;
begin
  InitialPos := Pos(StartTag, S);
  if InitialPos = 0 then
    result = ''
  else
  begin
    Delete(S, 1, InitialPos + Length(StartTag) - 1);
    InitialPos := Pos(EndTag, S);
    if InitialPos = 0 then
      result := S
    else
    begin
      result := copy(S, 1, InitialPos - 1);
      Delete(S, 1, InitialPos + 1);
    end;
  end;
end;
//------------------------------------------------------------------------------------

procedure AnalyzePage(Address: string);
var
  Page: TStringList;
  LineNr: Integer;
  Line: string;
  Count: Integer;
  MovieTitle, MovieAddress: string;

begin
  Page := TStringList.Create;
  Page.Text := GetPage(Address);
  if Pos('<title>Busqueda de "', Page.Text) = 0 then
  begin
    ShowMessage('No se ha podido establecer la conexion.');
  end else
  begin
    LineNr := FindLine('resultados.</b></td></tr>', Page, 0);
    Line := Page.GetString(LineNr);
    Count := StrToInt(TextBetween (Line, '<b>', ' resultados.</b>'), 0);
    if Count = 0 then
    begin
      ShowMessage('No se han encontrado resultados para "' + MovieName + '"');
    end else
    begin
      PickTreeClear;
      PickTreeAdd('Encontrados ' + IntToStr(Count) + ' resultados para "' + MovieName + '"', '');

      LineNr := LineNr + 7;
      Line := Page.GetString(LineNr);
      repeat
        MovieTitle := TextBetween (Line, '.html">', '</a>');
        HTMLDecode(MovieTitle);
        Line := Page.GetString(LineNr);
        MovieAddress := TextBetween (Line, '<b><a href="', '">');
        PickTreeAdd(MovieTitle, BaseURL1 + MovieAddress);
        LineNr := LineNr + 10;
        Line := Page.GetString(LineNr);
      until Pos('</table>', Line) > 0;

      if PickTreeExec(Address) then
        AnalyzeMoviePage(Address);
    end;
  end;
  Page.Free;
end;
//------------------------------------------------------------------------------------

procedure AnalyzeMoviePage(Address: string);
var
  Page: TStringList;
  LineNr, aux: Integer;
  Line: string;
  Item: string;
  Comments: string;
  Actors: string;
  Directors: string;

begin
  Comments := '';
  Actors := '';

  // URL
  SetField(fieldURL, Address);

  Page := TStringList.Create;
  Page.Text := GetPage(Address);

  // Translated Title
  LineNr := FindLine('<div style="margin-bottom: 4; padding:1; text-align: left; border-bottom: 1px solid #990000;"><span style="color:#990000; font-size:16; font-weight: bold;">', Page, 0);
  Line := Page.GetString(LineNr);
  Item := TextBetween (Line, ' border="0"> ', '</span>');
  HTMLDecode(Item);
  SetField(fieldTranslatedTitle, Trim (Item));

  // Original Title
  LineNr := FindLine('TITULO ORIGINAL', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td ><b>', '</b></td>');
    HTMLDecode(Item);
    SetField(fieldOriginalTitle, Trim (Item));
  end;

  // Picture
  LineNr := FindLine('owned by Studio', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr);
    Item := TextBetween (Line, '<img src="', '">');
    if Pos (BaseURL1, Item) <> 0 then
      Item := TextBetween (Item, BaseURL1, '"');
    GetPicture (BaseURL1 + Item);
  end;

  // Year
  LineNr := FindLine('AÑO', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td >', '</td>');
    HTMLDecode(Item);
    SetField(fieldYear, Trim (Item));
  end;

  // Length
  LineNr := FindLine('DURACIÓN', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td >', ' min.</td>');
    HTMLDecode(Item);
    SetField(fieldLength, Trim (Item));
  end;

  // Country
  LineNr := FindLine('PAÍS', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, 'alt="', '" border');
    HTMLDecode(Item);
    SetField(fieldCountry, Trim (Item));
  end;

  // Director
  LineNr := FindLine('DIRECTOR', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Directors := '';
    while Pos ('stype=director', Line) > 0 do
    begin
      Item := TextBetween (Line, '">', '</a>');
      HTMLDecode(Item);
      if Directors = '' then
        Directors := Item
      else
        Directors := Directors + ', ' + Item;
    end;
    SetField(fieldDirector, Trim (Directors));
  end;

  // Script writer
  LineNr := FindLine('GUIÓN', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td >', '</td>');
    Comments := Comments + 'Guión: ' + Item + #13#10;
  end;

  // Composer
  LineNr := FindLine('MUSICA', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td  >', '</td>');
    Comments := Comments + 'Música: ' + Item + #13#10;
  end;

  // Photography
  LineNr := FindLine('FOTOGRAFÍA', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td  >', '</td>');
    Comments := Comments + 'Fotografía: ' + Item + #13#10;
  end;

  // Actors
  LineNr := FindLine('REPARTO', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Actors := TextBetween (Line, '">', '</a>') + #13#10;
    while Pos ('stype=cast', Line) > 0 do
      Actors := Actors + TextBetween (Line, '"> ', '</a>') + #13#10;
    HTMLDecode(Actors);
    SetField(fieldActors, Actors);
  end;

  // Productor
  LineNr := FindLine('PRODUCTORA', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td  >', '</td>');
    HTMLDecode(Item);
    SetField(fieldProducer, Trim (Item));
  end;
   
  // Genere & Critic
  LineNr := FindLine('GÉNERO Y CRÍTICA', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    HTMLDecode(Line);
    Item := TextBetween (Line, '<td  >', '</td>');
    if Pos (' / ', Item) <> 0 then
    begin
      Line := Item;
      Item := Copy (Item, 1, Pos (' / ', Item));
      Line := TextBetween (Line, ' / ', '<br />');
      if Pos (' / ', Line) <> 0 then
      begin
        Comments := Comments + Item + #13#10;
        Item := Line;
        Item := Copy (Item, 1, Pos (' / ', Item));
        Line := TextBetween (Line, ' / ', '</td>');
        SetField(fieldCategory, Trim(Item));
        SetField(fieldDescription, Line);
      end
      else
      begin
        SetField(fieldCategory, Trim(Item));
        SetField(fieldDescription, Line);
      end
    end
    else
      SetField(fieldCategory, Trim(Item));
  end;

  // Official Webpage
  LineNr := FindLine('WEB OFICIAL', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Comments := Comments + 'Web oficial: ' + TextBetween (Line, '<a href="', '" target="_blank">') + #13#10;
  end;

  // Rating
  LineNr := FindLine('<td align="center" style="color:#990000; font-size:22px; font-weight: bold;">', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr);
    Item := TextBetween (Line, '<td align="center" style="color:#990000; font-size:22px; font-weight: bold;">', '</td>');
    HTMLDecode(Item);
    SetField(fieldRating, Item);
  end;

  HTMLDecode(Comments);
  SetField(fieldComments, Comments);
end;
//------------------------------------------------------------------------------------
//------------------------------------------------------------------------------------

begin
  if CheckVersion(3,5,0) then
  begin
    MovieName := GetField(fieldOriginalTitle);
    if MovieName = '' then
      MovieName := GetField(fieldTranslatedTitle);
    if Input('Importar de FilmAffinity', 'Introduzca el titulo de la pelicula:', MovieName) then
    begin
      AnalyzePage(SearchBaseURL + UrlEncode(MovieName) + SearchPostfix);
    end;
  end
  else
    ShowMessage('Este script requiere una version mas reciente de Ant Movie Catalog (por lo menos la version 3.5.0)');
end.
antp
Site Admin
Posts: 9630
Joined: 2002-05-30 10:13:07
Location: Brussels
Contact:

Post by antp »

A new spanish script:
http://antp.be/temp/scripts/SDG%20(ES).ifs
for www.sdg-es.com
(send by the webmaster of the site, because one of the members of the site made this script)
Juanra
Posts: 9
Joined: 2004-02-25 19:23:49

Re: Solucion al error Forbiden HTTP 1.1/403

Post by Juanra »

Pues el de FilmAffinity vuelve a no funcionar, me da "error de script en Filmaffinity:assignment expected en la linea 35"

Saludos
:??: [/img]
folgui
Posts: 113
Joined: 2003-02-04 19:15:03
Location: Madrid, Spain

Post by folgui »

Hello Juara!

It works for me (the last version included in version 3.5.0.2 of AMC...¿it happens with all movies or just someone?

Regards, folgui
darts501

error assignement in line 56

Post by darts501 »

error assignement in line 56 in all films onlu in film with number
11:14 make an error
Juanra
Posts: 9
Joined: 2004-02-25 19:23:49

Post by Juanra »

folgui wrote:Hello Juara!

It works for me (the last version included in version 3.5.0.2 of AMC...¿it happens with all movies or just someone?

Regards, folgui
Well, it seems to happen only with 11:14 Destino fatal, not with other films. I tried with '11:14', 'destino', 'fatal', 'destino fatal' and always the same error. Seems to be a 'fatal film' :hihi:
Regards.
Spanish: Bueno, parece que pasa sólo con 11:14 Destino fatal, no con otras películas. Lo he intentado con '11:14', 'destino', 'fatal', 'destino fatal' y siempre da el mismo error. Parece que sea una 'película fatal' :hihi: Saludos.

P.S. I performed a search in FilmAffinity site and the film does exist in its database.

P.D. He realizado una búsqueda en el sitio de FilmAffinity y la película sí que existe en su base de datos.
folgui
Posts: 113
Joined: 2003-02-04 19:15:03
Location: Madrid, Spain

Post by folgui »

Hello!

As darts501 already said, the script has a bug at the TextBetween function, at the beginning an asignment is missing:

Code: Select all

  InitialPos := Pos(StartTag, S);
  if InitialPos = 0 then
    result = ''
  else 
should be

Code: Select all

  InitialPos := Pos(StartTag, S);
  if InitialPos = 0 then
    result := ''
  else 
This fixes an error message but it doesn't fix the script, since it doesn't catch when MovieName = '' in the AnalyzePage function.

This bug/fix is about the error you see when you search for the next movie:

With the "11:14 Destino fatal" movie the script fails to get the title/address of the second movie found when we search for "Destino fatal" and doesn't get out of the "repeat" of the code and crashes.

But it works perfectly if you search for "14" because it only finds one movie and doesn't crash, and the result is the film you are looking for :grinking:

By the way, the script must be changed with "uses StringUtils1;" at the beginning and deleting the two functions already included in that unit (FindLine and TextBetween).

Hope i've helped you and that spanish users don't have any problem to understand the text.

Regards, folgui ;)
Juanra
Posts: 9
Joined: 2004-02-25 19:23:49

Post by Juanra »

Ok. Fixed the bug and it works now; searching for '11' or for '14' finds the movie.

Thanks a lot.
Marginal®

FilmAffinity script

Post by Marginal® »

Por Favor alguién que ponga el script ya una vez solucionado el error de la línea 35 porque no soy capaz de solucionarlo.
Gracias.
Un Saludo
javilp

Post by javilp »

simplemente sustituye
result = ' '
por

result := ' '

(añadiendo dos puntos antes del igual)
rodpedja
Posts: 5
Joined: 2005-06-05 19:16:42

Pequeña modificación

Post by rodpedja »

He modificado el script de
filmaffinity, porque no funcionaban bien algunos campos. En realidad
sólo he cambiado, algunas cadenas de busqueda, por ejemplo donde ponía
PAÍS ahora he puesto PAÍS, y así con todos los campos que no
funcionaban. No he tocado ningun otro procedimiento, salvo la linea 35, que he cambiado el = por el :=.
Un saludo

Code: Select all

program FilmAffinity;

const
  SearchBaseURL = 'http://new.filmaffinity.com/es/res.php?stext=';
  SearchPostFix = '&stype=tit';
  BaseURL1 = 'http://new.filmaffinity.com';

var
  MovieName: string;
  MovieURL: string;
//------------------------------------------------------------------------------------

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;
//------------------------------------------------------------------------------------

function TextBetween(var S: string; StartTag: string; EndTag: string): string;
var
  InitialPos: Integer;
begin
  InitialPos := Pos(StartTag, S);
  if InitialPos = 0 then
    result := ''
  else
  begin
    Delete(S, 1, InitialPos + Length(StartTag) - 1);
    InitialPos := Pos(EndTag, S);
    if InitialPos = 0 then
      result := S
    else
    begin
      result := copy(S, 1, InitialPos - 1);
      Delete(S, 1, InitialPos + 1);
    end;
  end;
end;
//------------------------------------------------------------------------------------

procedure AnalyzePage(Address: string);
var
  Page: TStringList;
  LineNr: Integer;
  Line: string;
  Count: Integer;
  MovieTitle, MovieAddress: string;

begin
  Page := TStringList.Create;
  Page.Text := GetPage(Address);
  if Pos('<title>Busqueda de "', Page.Text) = 0 then
  begin
    ShowMessage('No se ha podido establecer la conexion.');
  end else
  begin
    LineNr := FindLine('resultados.</b></td></tr>', Page, 0);
    Line := Page.GetString(LineNr);
    Count := StrToInt(TextBetween (Line, '<b>', ' resultados.</b>'), 0);
    if Count = 0 then
    begin
      ShowMessage('No se han encontrado resultados para "' + MovieName + '"');
    end else
    begin
      PickTreeClear;
      PickTreeAdd('Encontrados ' + IntToStr(Count) + ' resultados para "' + MovieName + '"', '');

      LineNr := LineNr + 7;
      Line := Page.GetString(LineNr);
      repeat
        MovieTitle := TextBetween (Line, '.html">', '</a>');
        HTMLDecode(MovieTitle);
        Line := Page.GetString(LineNr);
        MovieAddress := TextBetween (Line, '<b><a href="', '">');
        PickTreeAdd(MovieTitle, BaseURL1 + MovieAddress);
        LineNr := LineNr + 10;
        Line := Page.GetString(LineNr);
      until Pos('</table>', Line) > 0;

      if PickTreeExec(Address) then
        AnalyzeMoviePage(Address);
    end;
  end;
  Page.Free;
end;
//------------------------------------------------------------------------------------

procedure AnalyzeMoviePage(Address: string);
var
  Page: TStringList;
  LineNr, aux: Integer;
  Line: string;
  Item: string;
  Comments: string;
  Actors: string;
  Directors: string;

begin
  Comments := '';
  Actors := '';

  // URL
  SetField(fieldURL, Address);

  Page := TStringList.Create;
  Page.Text := GetPage(Address);

  // Translated Title
  LineNr := FindLine('<div style="margin-bottom: 4; padding:1; text-align: left; border-bottom: 1px solid #990000;"><span style="color:#990000; font-size:16; font-weight: bold;">', Page, 0);
  Line := Page.GetString(LineNr);
  Item := TextBetween (Line, ' border="0"> ', '</span>');
  HTMLDecode(Item);
  SetField(fieldTranslatedTitle, Trim (Item));

  // Original Title
  LineNr := FindLine('TITULO ORIGINAL', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td ><b>', '</b></td>');
    HTMLDecode(Item);
    SetField(fieldOriginalTitle, Trim (Item));
  end;

  // Picture
  LineNr := FindLine('owned by Studio', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr);
    Item := TextBetween (Line, '<img src="', '">');
    if Pos (BaseURL1, Item) <> 0 then
      Item := TextBetween (Item, BaseURL1, '"');
    GetPicture (BaseURL1 + Item);
  end;

  // Year
  LineNr := FindLine('AÑO', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td >', '</td>');
    HTMLDecode(Item);
    SetField(fieldYear, Trim (Item));
  end;

  // Length
  LineNr := FindLine('DURACIÓN', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td >', ' min.</td>');
    HTMLDecode(Item);
    SetField(fieldLength, Trim (Item));
  end;

  // Country
  LineNr := FindLine('PAÍS', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, 'alt="', '" border');
    HTMLDecode(Item);
    SetField(fieldCountry, Trim (Item));
  end;

  // Director
  LineNr := FindLine('DIRECTOR', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Directors := '';
    while Pos ('stype=director', Line) > 0 do
    begin
      Item := TextBetween (Line, '">', '</a>');
      HTMLDecode(Item);
      if Directors = '' then
        Directors := Item
      else
        Directors := Directors + ', ' + Item;
    end;
    SetField(fieldDirector, Trim (Directors));
  end;

  // Script writer
  LineNr := FindLine('GUIÓN', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td >', '</td>');
    Comments := Comments + 'Guión: ' + Item + #13#10;
  end;

  // Composer
  LineNr := FindLine('MUSICA', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td  >', '</td>');
    Comments := Comments + 'Música: ' + Item + #13#10;
  end;

  // Photography
  LineNr := FindLine('FOTOGRAFÍA', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td  >', '</td>');
    Comments := Comments + 'Fotografía: ' + Item + #13#10;
  end;

  // Actors
  LineNr := FindLine('REPARTO', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Actors := TextBetween (Line, '">', '</a>') + #13#10;
    while Pos ('stype=cast', Line) > 0 do
      Actors := Actors + TextBetween (Line, '"> ', '</a>') + #13#10;
    HTMLDecode(Actors);
    SetField(fieldActors, Actors);
  end;

  // Productor
  LineNr := FindLine('PRODUCTORA', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td  >', '</td>');
    HTMLDecode(Item);
    SetField(fieldProducer, Trim (Item));
  end;
   
  // Genere & Critic
  LineNr := FindLine('GÉNERO Y CRÍTICA', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    HTMLDecode(Line);
    Item := TextBetween (Line, '<td  >', '</td>');
    if Pos (' / ', Item) <> 0 then
    begin
      Line := Item;
      Item := Copy (Item, 1, Pos (' / ', Item));
      Line := TextBetween (Line, ' / ', '<br />');
      if Pos (' / ', Line) <> 0 then
      begin
        Comments := Comments + Item + #13#10;
        Item := Line;
        Item := Copy (Item, 1, Pos (' / ', Item));
        Line := TextBetween (Line, ' / ', '</td>');
        SetField(fieldCategory, Trim(Item));
        SetField(fieldDescription, Line);
      end
      else
      begin
        SetField(fieldCategory, Trim(Item));
        SetField(fieldDescription, Line);
      end
    end
    else
      SetField(fieldCategory, Trim(Item));
  end;

  // Official Webpage
  LineNr := FindLine('WEB OFICIAL', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Comments := Comments + 'Web oficial: ' + TextBetween (Line, '<a href="', '" target="_blank">') + #13#10;
  end;

  // Rating
  LineNr := FindLine('<td align="center" style="color:#990000; font-size:22px; font-weight: bold;">', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr);
    Item := TextBetween (Line, '<td align="center" style="color:#990000; font-size:22px; font-weight: bold;">', '</td>');
    HTMLDecode(Item);
    SetField(fieldRating, Item);
  end;

  HTMLDecode(Comments);
  SetField(fieldComments, Comments);
end;
//------------------------------------------------------------------------------------
//------------------------------------------------------------------------------------

begin
  if CheckVersion(3,5,0) then
  begin
    MovieName := GetField(fieldOriginalTitle);
    if MovieName = '' then
      MovieName := GetField(fieldTranslatedTitle);
    if Input('Importar de FilmAffinity', 'Introduzca el titulo de la pelicula:', MovieName) then
    begin
      AnalyzePage(SearchBaseURL + UrlEncode(MovieName) + SearchPostfix);
    end;
  end
  else
    ShowMessage('Este script requiere una version mas reciente de Ant Movie Catalog (por lo menos la version 3.5.0)');
end.
folgui
Posts: 113
Joined: 2003-02-04 19:15:03
Location: Madrid, Spain

Post by folgui »

Hello rodpedja!

Thanks for update.

Can you edit your post and paste also que header of original script, so it's full? More simple to copy/paste/save to FilmAffinity(ES).ifs

Also, as you posted the lastest working one, it should be good to update version number (in header) to 1.1 for example.

Regards, folgui.
rodpedja
Posts: 5
Joined: 2005-06-05 19:16:42

Last Version del Script

Post by rodpedja »

Aqui os pongo la ultima version de este script realizado por aviloria, y modificado por mi, rodpedja. Las modificaciones respecto al original son muy pequeñas, pero suficientes para que funcione correctamente.
Un saludo

Code: Select all

(***************************************************

Ant Movie Catalog importation script
www.antp.be/software/moviecatalog/

[Infos]
Authors=aviloria  (aviloria@yahoo.com) modded by rodpedja (rodpedja@gmail.com)
Title=FilmAffinity (ES)
Description=Movie importation script for FilmAffinity Spain
Site=http://www.filmaffinity.com
Language=ES
Version=1.25
Requires=3.5.0
Comments=Updated to the new beta version of the page | Previous version is unsupported.
License=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.|
GetInfo=1

[Options]

***************************************************)

program FilmAffinity;

const
  SearchBaseURL = 'http://new.filmaffinity.com/es/res.php?stext=';
  SearchPostFix = '&stype=tit';
  BaseURL1 = 'http://new.filmaffinity.com';

var
  MovieName: string;
  MovieURL: string;
//------------------------------------------------------------------------------------

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;
//------------------------------------------------------------------------------------

function TextBetween(var S: string; StartTag: string; EndTag: string): string;
var
  InitialPos: Integer;
begin
  InitialPos := Pos(StartTag, S);
  if InitialPos = 0 then
    result := ''
  else
  begin
    Delete(S, 1, InitialPos + Length(StartTag) - 1);
    InitialPos := Pos(EndTag, S);
    if InitialPos = 0 then
      result := S
    else
    begin
      result := copy(S, 1, InitialPos - 1);
      Delete(S, 1, InitialPos + 1);
    end;
  end;
end;
//------------------------------------------------------------------------------------

procedure AnalyzePage(Address: string);
var
  Page: TStringList;
  LineNr: Integer;
  Line: string;
  Count: Integer;
  MovieTitle, MovieAddress: string;

begin
  Page := TStringList.Create;
  Page.Text := GetPage(Address);
  if Pos('<title>Busqueda de "', Page.Text) = 0 then
  begin
    ShowMessage('No se ha podido establecer la conexion.');
  end else
  begin
    LineNr := FindLine('resultados.</b></td></tr>', Page, 0);
    Line := Page.GetString(LineNr);
    Count := StrToInt(TextBetween (Line, '<b>', ' resultados.</b>'), 0);
    if Count = 0 then
    begin
      ShowMessage('No se han encontrado resultados para "' + MovieName + '"');
    end else
    begin
      PickTreeClear;
      PickTreeAdd('Encontrados ' + IntToStr(Count) + ' resultados para "' + MovieName + '"', '');

      LineNr := LineNr + 7;
      Line := Page.GetString(LineNr);
      repeat
        MovieTitle := TextBetween (Line, '.html">', '</a>');
        HTMLDecode(MovieTitle);
        Line := Page.GetString(LineNr);
        MovieAddress := TextBetween (Line, '<b><a href="', '">');
        PickTreeAdd(MovieTitle, BaseURL1 + MovieAddress);
        LineNr := LineNr + 10;
        Line := Page.GetString(LineNr);
      until Pos('</table>', Line) > 0;

      if PickTreeExec(Address) then
        AnalyzeMoviePage(Address);
    end;
  end;
  Page.Free;
end;
//------------------------------------------------------------------------------------

procedure AnalyzeMoviePage(Address: string);
var
  Page: TStringList;
  LineNr, aux: Integer;
  Line: string;
  Item: string;
  Comments: string;
  Actors: string;
  Directors: string;

begin
  Comments := '';
  Actors := '';

  // URL
  SetField(fieldURL, Address);

  Page := TStringList.Create;
  Page.Text := GetPage(Address);

  // Translated Title
  LineNr := FindLine('<div style="margin-bottom: 4; padding:1; text-align: left; border-bottom: 1px solid #990000;"><span style="color:#990000; font-size:16; font-weight: bold;">', Page, 0);
  Line := Page.GetString(LineNr);
  Item := TextBetween (Line, ' border="0"> ', '</span>');
  HTMLDecode(Item);
  SetField(fieldTranslatedTitle, Trim (Item));

  // Original Title
  LineNr := FindLine('TITULO ORIGINAL', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td ><b>', '</b></td>');
    HTMLDecode(Item);
    SetField(fieldOriginalTitle, Trim (Item));
  end;

  // Picture
  LineNr := FindLine('owned by Studio', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr);
    Item := TextBetween (Line, '<img src="', '">');
    if Pos (BaseURL1, Item) <> 0 then
      Item := TextBetween (Item, BaseURL1, '"');
    GetPicture (BaseURL1 + Item);
  end;

  // Year
  LineNr := FindLine('AÑO', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td >', '</td>');
    HTMLDecode(Item);
    SetField(fieldYear, Trim (Item));
  end;

  // Length
  LineNr := FindLine('DURACIÓN', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td >', ' min.</td>');
    HTMLDecode(Item);
    SetField(fieldLength, Trim (Item));
  end;

  // Country
  LineNr := FindLine('PAÍS', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, 'alt="', '" border');
    HTMLDecode(Item);
    SetField(fieldCountry, Trim (Item));
  end;

  // Director
  LineNr := FindLine('DIRECTOR', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Directors := '';
    while Pos ('stype=director', Line) > 0 do
    begin
      Item := TextBetween (Line, '">', '</a>');
      HTMLDecode(Item);
      if Directors = '' then
        Directors := Item
      else
        Directors := Directors + ', ' + Item;
    end;
    SetField(fieldDirector, Trim (Directors));
  end;

  // Script writer
  LineNr := FindLine('GUIÓN', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td >', '</td>');
    Comments := Comments + 'Guión: ' + Item + #13#10;
  end;

  // Composer
  LineNr := FindLine('MUSICA', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td  >', '</td>');
    Comments := Comments + 'Música: ' + Item + #13#10;
  end;

  // Photography
  LineNr := FindLine('FOTOGRAFÍA', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td  >', '</td>');
    Comments := Comments + 'Fotografía: ' + Item + #13#10;
  end;

  // Actors
  LineNr := FindLine('REPARTO', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Actors := TextBetween (Line, '">', '</a>') + #13#10;
    while Pos ('stype=cast', Line) > 0 do
      Actors := Actors + TextBetween (Line, '"> ', '</a>') + #13#10;
    HTMLDecode(Actors);
    SetField(fieldActors, Actors);
  end;

  // Productor
  LineNr := FindLine('PRODUCTORA', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Item := TextBetween (Line, '<td  >', '</td>');
    HTMLDecode(Item);
    SetField(fieldProducer, Trim (Item));
  end;
   
  // Genere & Critic
  LineNr := FindLine('GÉNERO Y CRÍTICA', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    HTMLDecode(Line);
    Item := TextBetween (Line, '<td  >', '</td>');
    if Pos (' / ', Item) <> 0 then
    begin
      Line := Item;
      Item := Copy (Item, 1, Pos (' / ', Item));
      Line := TextBetween (Line, ' / ', '<br />');
      if Pos (' / ', Line) <> 0 then
      begin
        Comments := Comments + Item + #13#10;
        Item := Line;
        Item := Copy (Item, 1, Pos (' / ', Item));
        Line := TextBetween (Line, ' / ', '</td>');
        SetField(fieldCategory, Trim(Item));
        SetField(fieldDescription, Line);
      end
      else
      begin
        SetField(fieldCategory, Trim(Item));
        SetField(fieldDescription, Line);
      end
    end
    else
      SetField(fieldCategory, Trim(Item));
  end;

  // Official Webpage
  LineNr := FindLine('WEB OFICIAL', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr + 1);
    Comments := Comments + 'Web oficial: ' + TextBetween (Line, '<a href="', '" target="_blank">') + #13#10;
  end;

  // Rating
  LineNr := FindLine('<td align="center" style="color:#990000; font-size:22px; font-weight: bold;">', Page, 0);
  if LineNr <> -1 then
  begin
    Line := Page.GetString(LineNr);
    Item := TextBetween (Line, '<td align="center" style="color:#990000; font-size:22px; font-weight: bold;">', '</td>');
    HTMLDecode(Item);
    SetField(fieldRating, Item);
  end;

  HTMLDecode(Comments);
  SetField(fieldComments, Comments);
end;
//------------------------------------------------------------------------------------
//------------------------------------------------------------------------------------

begin
  if CheckVersion(3,5,0) then
  begin
    MovieName := GetField(fieldOriginalTitle);
    if MovieName = '' then
      MovieName := GetField(fieldTranslatedTitle);
    if Input('Importar de FilmAffinity', 'Introduzca el titulo de la pelicula:', MovieName) then
    begin
      AnalyzePage(SearchBaseURL + UrlEncode(MovieName) + SearchPostfix);
    end;
  end
  else
    ShowMessage('Este script requiere una version mas reciente de Ant Movie Catalog (por lo menos la version 3.5.0)');
end.
 ;)  ;) 
user

Ya no aparecen las criticas

Post by user »

Con el nuevo script de filmaffinity, en el apartado de descripción ya no aparecen las criticas, solo aparece la sinopsis de filmaffinity, ¿Podria alguien conseguir q volviesen a aparecer?

Gracias
FJGONZALEZB

ERROR AL EJECUTAR EL SCRIPT "No se encontró película ..

Post by FJGONZALEZB »

Cuando ejecuto el script obtengo:

" No se encontró película para los valores de limitación de script"

¿ Alguien sabe que estoy haciendo mal ?

Gracias.
Post Reply