English > Scripts and Templates
Allmovie Script
Ivek23:
Wanted to say
--- Quote ---You mean you want a script that
--- End quote ---
also at this link
--- Quote ---http://www.allmovie.com/dvd/100-girls-19609
--- End quote ---
of course if it were possible.
Ivek23:
Here
--- Code: --- //DVD Rating
AddCustomFieldValueByName('DVD rating', '0');
curPos := PosFrom('<img src="/img/st_r', HTML, EndPos);
if curPos > 0 then begin
curPos := PosFrom('alt="', HTML, curPos) + 5;
EndPos := PosFrom(' ', HTML, curPos);
AddCustomFieldValueByName('DVD rating', FloatToStr(StrToFloat(Copy(HTML, curPos, EndPos - curPos)) * 2));
end else
curPos := EndPos;
//Feature Rating
AddCustomFieldValueByName('Feature rating', '0');
curPos := PosFrom('<img src="/img/st_r', HTML, EndPos);
if curPos > 0 then begin
curPos := PosFrom('alt="', HTML, curPos) + 5;
EndPos := PosFrom(' ', HTML, curPos);
AddCustomFieldValueByName('Feature rating', FloatToStr(StrToFloat(Copy(HTML, curPos, EndPos - curPos)) * 2));
--- End code ---
from this link
http://www.allmovie.com/dvd/100-girls-19609
what needs to be corrected that even if this will work.
rick.ca:
First, you would somehow have to get to that page. That might be easy if there is only one DVD for a move, but usually there are many. As I said before, I don't believe user-interaction to select one DVD is possible with a script.
Ivek23:
Obviously it will be necessary to manually enter this address
http://www.allmovie.com/dvd/100-girls-19609
you must manually enter the url.However, this would then
--- Code: --- //DVD Rating
AddCustomFieldValueByName('DVD rating', '0');
curPos := PosFrom('<img src="/img/st_r', HTML, EndPos);
if curPos > 0 then begin
curPos := PosFrom('alt="', HTML, curPos) + 5;
EndPos := PosFrom(' ', HTML, curPos);
AddCustomFieldValueByName('DVD rating', FloatToStr(StrToFloat(Copy(HTML, curPos, EndPos - curPos)) * 2));
end else
curPos := EndPos;
//Feature Rating
AddCustomFieldValueByName('Feature rating', '0');
curPos := PosFrom('<img src="/img/st_r', HTML, EndPos);
if curPos > 0 then begin
curPos := PosFrom('alt="', HTML, curPos) + 5;
EndPos := PosFrom(' ', HTML, curPos);
AddCustomFieldValueByName('Feature rating', FloatToStr(StrToFloat(Copy(HTML, curPos, EndPos - curPos)) * 2));
--- End code ---
should work.I will inform how it works.
rick.ca:
--- Quote ---you must manually enter the url.
--- End quote ---
Where? ???
It might help if you explained what your are trying to do, and why.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version