Hola a todos,
Me he descargado este estupendo programa y lo he estado trasteando un poco. He creado unos campos: Guión, Música, Fotografía y Premios; y ahora quiero llenarlos automáticamente con algún script.
Por ejemplo, al conectarme a FilmAffinity, estos mismos campos salen en el apartado de comentarios y yo lo que quiero es dirigirlos a los campos que yo he creado.
He estado buscando por el foro, pero lo poco que he encontrado no me sirve.
¿Cómo podría resolver esto? ¿Saben de algún tutorial que ya esté creado? (No importa si no está en español).
Muchas gracias.
I'm sorry. My english is very bad.
[ES] Campos personalizados
Hi,
You have to change the script FilmAffinity to use your custom fields.
E.g. You can replace line 270 in script editor
by
and replace
by
And finally, replace YourCustomFieldTagWithThisQuotes with the tag you choose when you create the custom field
.
Soulsnake.
You have to change the script FilmAffinity to use your custom fields.
E.g. You can replace line 270 in script editor
Code: Select all
// Script writer
LineNr := FindLine('<th>GUIÓN</th>', Page, LineNr);
if LineNr <> -1 then
begin
Line := Page.GetString(LineNr + 1);
Item := TextBetween(Line, '<td>', '</td>');
Comments := Comments + 'Guión: ' + Item + #13#10 + #13#10;
end;
// Composer
LineNr := FindLine(' <th>MÚSICA</th>', Page, LineNr);
if LineNr <> -1 then
begin
Line := Page.GetString(LineNr + 1);
Item := TextBetween(Line, '<td>', '</td>');
Comments := Comments + 'Música: ' + Item + #13#10 + #13#10;
end;
// Photography
LineNr := FindLine('<th>FOTOGRAFÍA</th>', Page, LineNr);
if LineNr <> -1 then
begin
Line := Page.GetString(LineNr + 1);
Item := TextBetween(Line, '<td>', '</td>');
Comments := Comments + 'Fotografía: ' + Item + #13#10 + #13#10;
end;
Code: Select all
// Script writer
LineNr := FindLine('<th>GUIÓN</th>', Page, LineNr);
if LineNr <> -1 then
begin
Line := Page.GetString(LineNr + 1);
Item := TextBetween(Line, '<td>', '</td>');
//Comments := Comments + 'Guión: ' + Item + #13#10 + #13#10;
SetCustomField('YourCustomFieldTagWithThisQuotes', Item);
end;
// Composer
LineNr := FindLine(' <th>MÚSICA</th>', Page, LineNr);
if LineNr <> -1 then
begin
Line := Page.GetString(LineNr + 1);
Item := TextBetween(Line, '<td>', '</td>');
//Comments := Comments + 'Música: ' + Item + #13#10 + #13#10;
SetCustomField('YourCustomFieldTagWithThisQuotes', Item);
end;
// Photography
LineNr := FindLine('<th>FOTOGRAFÍA</th>', Page, LineNr);
if LineNr <> -1 then
begin
Line := Page.GetString(LineNr + 1);
Item := TextBetween(Line, '<td>', '</td>');
//Comments := Comments + 'Fotografía: ' + Item + #13#10 + #13#10;
SetCustomField('YourCustomFieldTagWithThisQuotes', Item);
end;
Code: Select all
// Awards
LineNr := FindLine('<th>PREMIOS</th>', Page, LineNr);
if LineNr <> -1 then
begin
LineNr := LineNr + 1;
Line := Page.GetString(LineNr);
Comments := Comments + 'Premios: ' + #13#10;
while Pos('<a href="/es/awards.php', Line) > 0 do
begin
Item := DeleteTags(Line);
Comments := Comments + ' - ' + Trim(Item) + #13#10;
LineNr := LineNr + 1;
Line := Page.GetString(LineNr);
end;
Comments := Comments + #13#10;
end;
Code: Select all
// Awards
LineNr := FindLine('<th>PREMIOS</th>', Page, LineNr);
if LineNr <> -1 then
begin
LineNr := LineNr + 1;
Line := Page.GetString(LineNr);
//Comments := Comments + 'Premios: ' + #13#10;
SetCustomField('YourCustomFieldTagWithThisQuotes', '');
while Pos('<a href="/es/awards.php', Line) > 0 do
begin
Item := DeleteTags(Line);
//Comments := Comments + ' - ' + Trim(Item) + #13#10;
SetCustomField('YourCustomFieldTagWithThisQuotes', GetCustomField('YourCustomFieldTagWithThisQuotes') + ' - ' + Trim(Item) + #13#10);
LineNr := LineNr + 1;
Line := Page.GetString(LineNr);
end;
//Comments := Comments + #13#10;
end;

Soulsnake.
Yes, its work. Thank you so much.
I have other question.
I want to use this fields with Ant Movie Catalog Viewer.
What is the code?
<p><b>guión<br></b>$$GUION</p>??
Thank you, soulsnake
I have other question.
I want to use this fields with Ant Movie Catalog Viewer.
Code: Select all
<p><b>Género<br></b>$CATEGORY</p>
<p><b>Duración<br></b>$LENGTH Minutes</p>
<p><b>Director<br></b>$DIRECTOR</p>
<p><b>Reparto<br></b>$ACTORS</p>
<p><b>Productora<br></b>$PRODUCER</p>
<p><b>Sinopsis<br></b>$DESCRIPTION</p>
<p><b>Comentarios<br></b>$COMMENTS</p>
<p><b>guión<br></b>$$GUION</p>??
Thank you, soulsnake
Hi,
I update Ant Viewer to add full custom fields support and fix some bugs
.
See: viewtopic.php?p=34437
Soulsnake.
I update Ant Viewer to add full custom fields support and fix some bugs

See: viewtopic.php?p=34437
Soulsnake.