Post reply

Warning: this topic has not been posted in for at least 120 days.
Unless you're sure you want to reply, please consider starting a new topic.

Note: this post will not display until it's been approved by a moderator.

Name:
Email:
Subject:
Message icon:

Attach:
(Clear Attachment)
(more attachments)
Allowed file types: gif, jpg, png, txt, tpl, lng, ini, pvd, psf, ini, cfg, csv, zip, xml, pas, 7z
Restrictions: 4 per post, maximum total size 1024KB, maximum individual size 1024KB
Note that any files attached will not be displayed until approved by a moderator.
Verification:
Type the letters shown in the picture
Listen to the letters / Request another image

Type the letters shown in the picture:
How many words are in this question?:

shortcuts: hit alt+s to submit/post or alt+p to preview


Topic Summary

Posted by: Ivek23
« on: December 10, 2013, 02:02:31 pm »

ONLY TITLE is my problem. My scripts run well.

ONLY TITLE

For TITLE I can not help it.
Posted by: nika-model
« on: December 10, 2013, 12:47:10 pm »

STOP.
I haven't Problem with another Fields.
ONLY TITLE is my problem. My scripts run well.

ONLY TITLE 

Date was example....
Posted by: Ivek23
« on: December 09, 2013, 07:24:05 pm »

For Year I need only 4 digits from end and unformated date i save to Custom Field.

For Year maybe this help:

Code: [Select]
//~mfYear~ or ~Year~

endPos := PosFrom('</span></h1>', HTML, curPos);
curPos := endPos - 5;
TmpStr2 := IntToStr(StrToInt(Copy(HTML, curPos, 4)));

if TmpStr2 = '0' then
TmpStr2 := '';

AddFieldValue(mfYear, TmpStr2);
AddCustomFieldValueByName('Year', TmpStr2);

if TmpStr2 = '' then
TmpStr2 := 'year unknown';

LogMessage(' Parsing: ' + TmpStr1 + '(' + TmpStr2 + ')');

For Date maybe this help:

Code: [Select]
procedure ParseMovie(MovieURL : String; HTML : String);
var
curPos, endPos : Integer;
Date, TmpStr, TmpStr1, TmpStr2, TmpStr3, TmpStr4, TmpStr5 : String;
DateParts: TWideArray;
begin

//Date ~Updated~ (choose simple or verbose version)
Date := DateToStr(CurrentDateTime);
if Date <> '' then
  begin
    ExplodeString(Date, DateParts, '-');
Date := DateParts[2] +'.'+ DateParts[1] +'.'+ DateParts[0];
AddCustomFieldValueByName('Updated', Date);  // Simple
  end else
    LogMessage('date not found');

For the rest a little harder to help.
Posted by: nika-model
« on: December 09, 2013, 06:06:50 pm »

 This is a problem. Original Title you can update. But TITLE is a Name for your "Movie Tree" (left side tree). Then you need to know first right title of yours movie and then you can edit with script other fields. Field TITLE can't you updated. This was my problem. I can do Custom Field too. I did it for unformated date. Onetime is Oct 15, 2013 second time is Friday Oct 15, 2013 ... For Year I need only 4 digits from end and unformated date i save to Custom Field.

Field TITLE
for XML      'title'
for AField   '1'

is for nothing. You can't there write data with script. :(

Posted by: Ivek23
« on: December 09, 2013, 05:55:09 pm »

Try if this will work.

Code: [Select]
AddFieldValueXML('title', New Name);
or
AddFieldValue(mfTitle, New Name);

Change 'title' to 'origtitle' :

Code: [Select]
AddFieldValueXML('origtitle', New Name);
or
AddFieldValue(mfOrigTitle, New Name);

If it does not work, ask for Nostra, if you can help.
Posted by: nika-model
« on: December 09, 2013, 03:48:58 pm »

This is the same what I wrote.

variable

newname := 'New Name Movie';


procedure....

Add..

I can update all others fields, but only TITLE I can't.
example:

       desc := TextBetween(HTML, '<p class="para-class t-para">', '</p>', False, iEndPos);
       LogMessage('-------> ParseMovie - Popis : ' + desc);   
       AddFieldValue(mfDescription, desc);   

This works.


Posted by: Ivek23
« on: December 09, 2013, 03:39:49 pm »

Try this, maybe help.

Code: [Select]
procedure ParseMovie(MovieURL : String; HTML : String);
var
curPos, endPos : Integer;
New Name : String;
begin

.
.
.

AddFieldValueXML('title', New Name);
or
AddFieldValue(mfTitle, New Name);
Posted by: nika-model
« on: December 09, 2013, 02:52:17 pm »

Hi all,
i want speak about theme "TITLE UPDATE".

Example:
Push Button PLUS(New Item), Set Name ("Test Name Title") and Apply Changes.

Now I have script who take from field URL. Then from this URL extrac Site Name, Movie Name, Release, TITLE.....
When I used

mfTitle := 1;

AddFieldValueXML('title', 'New Name');
or
AddFieldValue(mfTitle, 'New Name');

nothing happen. Title (Name of Movie) is still  ("Test Name Title").
How can I update this Field.
anything