I have a question:
Would it be possible (if at all possible), how to make the code for Similar Works and Other Related Works for example at this site: http://www.allmovie.com/work/the-matrix-177524
Maybe even both codes in a custom field, for example in the field Awards.
Thanks for the reply and effort in advance.
Partly I found the code for the
Similar Works and Other Related Works but fails to find a solution so please help.
Here are examples of what the partial results, I came.
Example 1.) :
Code:
//Features (Similar Works)
curPos := PosFrom('<td colspan="2" class="large-list-title" style="padding-top: 13px; padding-bottom: 1px;">', HTML, EndPos);
TmpStr := TextBetween(HTML, '<td colspan="2" class="large-list-title" style="padding-top: 13px; padding-bottom: 1px;">', '>Similar Works</td>', False, curPos);
TmpStr1 := StringReplace(TmpStr, '» <a href=', '', True, True, False);
If TmpStr1 <> '' then
AddCustomFieldValueByName('Similar Works', TmpStr1);
//Features (Other Related Works)
curPos := PosFrom('<td colspan="2" class="large-list-title" style="padding-top: 13px; padding-bottom: 1px;">', HTML, EndPos);
TmpStr := TextBetween(HTML, '<td colspan="2" class="large-list-title" style="padding-top: 13px; padding-bottom: 1px;">', '>Other Related Works</td>', False, curPos);
TmpStr1 := StringReplace(TmpStr, '» <a href=', '', True, True, False);
If TmpStr1 <> '' then
AddCustomFieldValueByName('Other Related Works', TmpStr1);
Result:
Links to other sites The dedication to my favorite movie! The Matrix Reloaded The Album The Matrix Community The official website <td colspan="2" class="large-list-title" style="padding-top: 13px; padding-bottom: 1px;"
or
Links to other sites The dedication to my favorite movie! The Matrix Reloaded The Album The Matrix Community The official website Similar Works Blade Runner (1982, Ridley Scott) Total Recall (1990, Paul Verhoeven) Logan's Run (1976, Michael Anderson) Johnny Mnemonic (1995, Robert Longo) Dark City (1998, Alex Proyas) 12:01 (1993, Jack Sholder) Demon Seed (1977, Donald Cammell) Metropolis (1927, Fritz Lang) The Aries Computer The Fifth Element (1997, Luc Besson) <td colspan="2" class="large-list-title" style="padding-top: 13px; padding-bottom: 1px;"[
On this page
http://www.allmovie.com/work/the-matrix-177524 so, where is just Similar Works has a score of zero downloads,but where, in addition Similar Works and Other Related Works is the result of only the transfer of Similar Works data in folder Other Related Works.
Example 2.) :
Code:
//Features (Similar Works)
curPos := PosFrom('<td colspan="2" class="large-list-title" style="padding-top: 13px; padding-bottom: 1px;">Similar Works</td>',HTML, EndPos);
AddCustomFieldValueByName('Similar Works', TextBetween(HTML,'<td colspan="2" class="large-list-title" style="padding-top: 13px; padding-bottom: 1px;">', '</td>', True, curPos));
//Features (Other Related Works)
curPos := PosFrom('<td colspan="2" class="large-list-title" style="padding-top: 13px; padding-bottom: 1px;">Other Related Works</td>',HTML, EndPos);
AddCustomFieldValueByName('Other Related Works', TextBetween(HTML,'<td colspan="2" class="large-list-title" style="padding-top: 13px; padding-bottom: 1px;">', '</td>', True, curPos));
end;
Result:
Similar Works
or
Other Related Works
Example 3.) :
Code:
//Features (Similar Works)
curPos := PosFrom('<td colspan="2" class="large-list-title" style="padding-top: 13px; padding-bottom: 1px;">Similar Works</td>', HTML, EndPos);
TmpStr := TextBetween(HTML, '<td>', '</td>', False, curPos);
TmpStr1 := StringReplace(TmpStr, '» <a href=', '', True, True, False);
If TmpStr1 <> '' then
AddCustomFieldValueByName('Similar Works', TmpStr1);
//Features (Other Related Works)
curPos := PosFrom('<td colspan="2" class="large-list-title" style="padding-top: 13px; padding-bottom: 1px;">Other Related Works</td>',HTML, EndPos);
TmpStr := TextBetween(HTML, '<td align="right" width="150">', '<td>', False, curPos);
TmpStr1 := TextBetween(HTML, '<td>', '</td>', False, curPos);
TmpStr1 := StringReplace(TmpStr, ' <td align=', '', True, True, False);
TmpStr2 := StringReplace(TmpStr1, '<td>', '', True, True, False);
TmpStr2 := StringReplace(TmpStr1, '» <a href=', '', True, True, False);
If TmpStr2 <> '' then
AddCustomFieldValueByName('Other Related Works', TmpStr2);
Result:
Blade Runner (1982, Ridley Scott)
or
Is followed by:
Here are transferred only the first type of data.
[attachment deleted by admin]