Search found 10 matches

by juliojs
2013-10-02 19:04:50
Forum: Ant Movie Catalog > Scripts
Topic: FilmAffinity (ES): New version of the script
Replies: 100
Views: 55498

soulsnake wrote:Hi,

Sorry for this bug.
It has already been fixed in AMC 4.2 beta.

Soulsnake.
Ahhh ok!

Thank you!!
by juliojs
2013-10-02 18:15:36
Forum: Ant Movie Catalog > Scripts
Topic: FilmAffinity (ES): New version of the script
Replies: 100
Views: 55498

Muy buenas. Tengo hace tiempo un problema con el script, y no encuentro forma de solucionarlo. En algunos casos pierde los decimales de la puntuación de la peli. Otras, la cambia a un valor incorrecto (grava un 6.5 en lugar del 6.6 publicado en la web, probado con "1984", por ejemplo). He...
by juliojs
2013-06-12 08:20:14
Forum: Ant Movie Catalog > Scripts
Topic: FilmAffinity (ES): New version of the script
Replies: 100
Views: 55498

Buenas! Antes de nada disculpas a AARON8888 por no contestar a los privados, pero es que no los he visto hasta ahora... XD Efectivamente hay veces que el script no encuentra la película si ésta tiene un nombre muy genérico, ya que aparece sepultada entre los resultados y el script sólo muestra los 2...
by juliojs
2013-05-12 16:24:57
Forum: Ant Movie Catalog > Scripts
Topic: FilmAffinity (ES): New version of the script
Replies: 100
Views: 55498

Muchas gracias por el nuevo script. ¿Alguien sabe como modificarlo para que me descargue la versión pequeña de la carátula? Gracias por adelantado ;-) --------------------- Thanks a lot for the new script. How can i modify the script to download the small cover? Thanks in advance Añade ésta línea a...
by juliojs
2013-04-26 08:13:23
Forum: Ant Movie Catalog > Scripts
Topic: Script Index dvd v1.2.1 by juliojs
Replies: 5
Views: 2881

Funciona perfectamente, muchas gracias Perfecto, pues a catalogar!! :D Hola! Lo primero darte las gracias por la ayuda! Te comento, a mi sólo me saca la carátula, no saca el resto de información, esto es correcto? saludos genio! Sí, en teoría éste script sólo es para obtener la carátula, le echaré ...
by juliojs
2013-04-26 08:08:09
Forum: Ant Movie Catalog > Scripts
Topic: FilmAffinity (ES): New version of the script
Replies: 100
Views: 55498

Disculpad el retraso en dar señales de vida... ando un tanto liado estos días y ni me había dado cuenta de los cambios en la web. @ juliojs : Muchas gracias por actualizar el script. He subido tus cambios al post inicial, he incrementado el número de versión y te he añadido como autor/colaborador. ...
by juliojs
2013-04-25 20:04:51
Forum: Ant Movie Catalog > Scripts
Topic: FilmAffinity (ES): New version of the script
Replies: 100
Views: 55498

javienigma wrote:Mil gracias!
No sé si tiene hilo, con el buscador no sale nada, así que he creado este post: viewtopic.php?t=5387&highlight=index
Gracias de verdad, yo para esto soy un inepto. Saludos!!!
Ok, gracias!

Creo que ya va el script, seguimos en su hilo... ;)
by juliojs
2013-04-25 20:03:18
Forum: Ant Movie Catalog > Scripts
Topic: Script Index dvd v1.2.1 by juliojs
Replies: 5
Views: 2881

He modificado un par de líneas y creo que ya funciona correctamente.

Saludos!

Code: Select all

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

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

[Infos]
Authors=Legrad modded by: juliojs
Title=IndexDVD caratula (ES)
Description=
Site=www.index-dvd.com
Language=ES
Version=1.2.1
Requires=3.5.0
Comments=
License=
GetInfo=1
RequiresMovies=1

[Options]

[Parameters]

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

 program IndexDVD;
var
  MovieName: string;
  MovieURL: string;

//------------------------------------------------------------------------------------
function Comillas(var S: string): string;
var
   n,len, tag: Integer;
   c: char;
   t: String;
begin
   tag := 0;
   t := '';
   len := length(s);
   for n :=1 to len do
   begin
     c := Copy(s,n,1);
     if c = '''' then
        c := ' ';
        t := t + c;
   end
   s := t;
   result := t;
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;
//------------------------------------------------------------------------------------
                      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;


//---------------------------------------------------------------------
function Caracter(str1: string) :string;
begin
          str1 := StringReplace(str1, 'á' , 'à');
          str1 := StringReplace(str1, 'é' , 'é');
          str1 := StringReplace(str1, 'í',  'í');
          Str1 := StringReplace(Str1, 'ó', 'ó');
          str1 := StringReplace(str1, 'ú' , 'ú');
          str1 := StringReplace(str1, 'ñ' , 'ñ');
          str1 := StringReplace(str1, 'Ã￾', 'Á');
          str1 := StringReplace(str1, 'É', 'É');
          str1 := StringReplace(str1, 'Ã￾', 'Í');
          str1 := StringReplace(str1, 'Ó', 'Ó');
          str1 := StringReplace(str1, 'Ú', 'Ú');
          str1 := StringReplace(str1, 'Ñ', 'Ñ');
          str1 := StringReplace(str1, 'Â', '');

result := str1;
end;//------------------------------------------------------------------------------------
                               function DeleteTags(var S: string): string;
var
   n,len, tag: Integer;
   c: char;
   t: String;
begin

   tag := 0;
   t := '';
   len := length(s);

   for n :=1 to len do
   begin
      c := Copy(s,n,1);


      if c = #9 then
         c := ' ';

      if(tag=1) then
      begin
         if(c='>') then tag := 0;
         continue;
      end
      else
      begin
         if(c='<') then
         begin
            tag := 1;
            continue;
         end;
         t := t + c;
      end;
   end
   s := t;
   result := t;
end;


//------------------------------------------------------------------------------------
procedure AnalyzePage(Address: string);
var
  strPage, MovieAddr, MovieTitle, MovieDate, MovieID, Movie: string;
  BeginPos, EndPos: Integer;
  BeginPoss, EndPoss: Integer;
begin
  strPage := GetPage(Address);
  BeginPos := Pos('ficha(s) encontrada(s)', strPage);
  if(BeginPos > -1)then
    begin
      PickTreeClear;
      Delete(strPage, 1, BeginPos);
      BeginPos := Pos('class=''texto3''> <a href=''http://www.index-dvd.com/', strPage);
      EndPos := 1;
      while ((BeginPos > 0) and (EndPos > 0)) do

        begin
          Delete(strPage, 1, BeginPos);
          EndPos := Pos('html', strPage);
          MovieId := Copy(strPage,+54, EndPos-54);

          MovieAddr := 'http://www.index-dvd.com/' + MovieId+'html';
          BeginPoss := Pos('title=',strPage);
          EndPoss := Pos('</td>', strPage);
          MovieTitle := Copy(strPage,BeginPoss, EndPoss);
          MovieTitle  := TextBetween(MovieTitle , '"', '" class');
          MovieTitle  := StringReplace(MovieTitle , 'DVD Video', ' (DVD)');
          MovieTitle  := StringReplace(MovieTitle , 'Cine', ' (CINE)');
          MovieTitle  := StringReplace(MovieTitle , 'Blu-Ray', ' (BLU-RAY)');
          MovieTitle  := StringReplace(MovieTitle , 'Alquiler', ' (ALQUILER)');
          DeleteTags(MovieTitle);
          MovieTitle := Caracter(MovieTitle);
          PickTreeAdd(MovieTitle,MovieAddr);
          PickTreeSort;
          BeginPos := Pos('class=''texto3''> <a href=''http://www.index-dvd.com/', strPage);
          if(Pos('</body>', strPage) < BeginPos) then
           BeginPos := -1;
        end;

    end;
    PickTreeExec(Address)
    AnalyzeMoviePage(Address);
end;
//------------------------------------------------------------------------------------
procedure AnalyzeMoviePage(Address: string);
var
  Page: TStringList;
  LineNr: Integer;
  Line: string;
  Item: string;
  dir: string;
  Comments: string;
  Actors: string;
  Directors: string;
  Description: string;
  Busca: integer;


begin
  Description := '';

  // URL
  //SetField(fieldURL, Address);

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

  // Caratula
  LineNr := FindLine('http://www.index-dvd.com/covers/300/', Page, 0);
  if LineNr > 0 then
  begin
    Item := copy(Page.Text, pos('http://www.index-dvd.com/covers/300/',Page.Text), length(Page.Text));
    Item := TextBetween (Item, 'http://www.index-dvd.com/covers/300/', '.jpg') + '.jpg';
    Item := StringReplace(Item, '300', '600');
    Item  := Trim(Item );
    GetPicture ('http://www.index-dvd.com/covers/600/'+Item);
     end;
  end;
 //-------------------------------------------------------------------------
begin
       if (CheckVersion(3,5,0)=FALSe) then
   begin
      ShowMessage('Se requiere Ant Movie Catalog versión 3.5 o superior');
      exit;
   end;

   MovieName := GetField(fieldTranslatedTitle);
   if MovieName = '' then
            MovieName := GetField(fieldOriginalTitle);
Input('IndexDVD', 'Buscar:', MovieName);

     if(GetOption('Sin resultado') = 0) then  Input('IndexDVD', 'Buscar:', MovieName);

   AnalyzePage('http://www.index-dvd.com/calendar_ult.php?tema=&order=tit&busqueda=' + UrlEncode(MovieName)+'&Submit.x=0&Submit.y=0');
end. 
by juliojs
2013-04-25 19:50:57
Forum: Ant Movie Catalog > Scripts
Topic: FilmAffinity (ES): New version of the script
Replies: 100
Views: 55498

Perfecto! funcionando, mil gracias! Sólo por curiosidad, cómo sabéis que líneas son las que fallan? oye, podrías please echar un ojo al script Index dvd? es muy bueno pero últimamente y desde hace un tiempo no funciona... gracias! Con un poco de nociones de php, html y usando el editor que viene co...
by juliojs
2013-04-25 19:19:29
Forum: Ant Movie Catalog > Scripts
Topic: FilmAffinity (ES): New version of the script
Replies: 100
Views: 55498

Buenas, He visto que el script no funcionaba con los nuevos cambios en la web y me he tomado la libertad de editarlo. Tan sólo he modificado un par de líneas y parece que ya funciona correctamente. Concretamente el código que fallaba era: LineNr := FindLine('<a class="mc-title" href="...