Allocine France - script adaptation

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.
Post Reply
Epsilon

Allocine France - script adaptation

Post by Epsilon »

re-salut !

Il semble qu'Allocine ait modifié leurs pages car les descriptions/Synopsis ne sont plus repris par les scripts.
Voici mon adaptation pour cette partie (le reste est ok).

// Description
LineNr := FindLine('Synopsis', Page, LineNr);
if LineNr > -1 then
begin
Line := Page.GetString(LineNr);
Value := '';
repeat
Line := Page.GetString(LineNr);
BeginPos := pos('"size2">', Line);
if BeginPos > 0 then
begin
BeginPos := BeginPos + 8;
end
LineNr := lineNr+1
until BeginPos > 0;
repeat
BeginPos := 1;
EndPos := pos('</FONT>', Line);
if EndPos = 0 then
EndPos := pos('<br>', Line);
if EndPos = 0 then
EndPos := Length(Line) + 1;
if EndPos > 0 then
Value := Value + copy(Line, BeginPos, EndPos - BeginPos) + #13#10;
EndPos := pos('</FONT>', Line);
if EndPos = 0 then
begin
LineNr := LineNr + 1;
Line := Page.GetString(LineNr);
end;
until EndPos > 0;
HTMLRemoveTags(Value);
SetField(fieldDescription, Value);
end;
antp
Site Admin
Posts: 9651
Joined: 2002-05-30 10:13:07
Location: Brussels
Contact:

Post by antp »

oui, mais ça avait déjà été corrigé, ça fait normalement partie des corrections de la version d'hier ;)
y avait déjà eu un topic :
viewtopic.php?t=163
mais c'est vrai qu'il était pas dans la bonne section :D

PS: pour mettre du code dans le forum, il vaut mieux utiliser les balises

Code: Select all

 ça permet de conserver les identations ;)
Post Reply