Author Topic: AllMovie+ script: Including data for custom fields  (Read 53431 times)

0 Members and 1 Guest are viewing this topic.

Offline nostra

  • Administrator
  • *****
  • Posts: 2852
    • View Profile
    • Personal Video Database
Re: AllMovie+ script: Including data for custom fields
« Reply #40 on: July 20, 2010, 01:16:24 am »
Post the whole script.

Quote
TmpStr1 := StringReplace(TmpStr, '<br />', #13#10, True, True, False);

This can only happen if the string does not contain "<br />"

Quote
It seems the Copy function removes the <br /> tags

No, it certainly does not remove anything

Quote
The result of the Copy function is a set of four CRLF between paragraphs

Then you can replace those with one line break.
Gentlemen, you can’t fight in here! This is the War Room!

Offline rick.ca

  • Global Moderator
  • *****
  • Posts: 3241
  • "I'm willing to shoot you!"
    • View Profile
Re: AllMovie+ script: Including data for custom fields
« Reply #41 on: July 20, 2010, 01:42:59 am »
Quote
No, it certainly does not remove anything

Maybe I misspoke. Let me put it this way: When I use only the Copy function to get the data, the <br /> tags that appeared to be in the source were not present (and apparently replaced by three CRLF's) in the imported text. No other tags "disappeared." Is this thing even a tag? It appears by itself, with no <br>. :-\

Quote
Then you can replace those with one line break.

Maybe whatever is going on with this <br /> is mute. Can you just show me how to replace multiple line breaks with one? StringReplace doesn't seem to do anything when I use #13#10 as OldPattern or NewPattern.
« Last Edit: July 21, 2010, 01:53:59 am by rick.ca »

Offline nostra

  • Administrator
  • *****
  • Posts: 2852
    • View Profile
    • Personal Video Database
Re: AllMovie+ script: Including data for custom fields
« Reply #42 on: July 21, 2010, 12:03:03 am »
The problem was:
1. The function RemoveTags used in the parsing procedure does not accept normal line breaks (only HTML tags)
2. You had to replace #13 with #13#10

Fixed script is attached

[attachment deleted by admin]
Gentlemen, you can’t fight in here! This is the War Room!

Offline rick.ca

  • Global Moderator
  • *****
  • Posts: 3241
  • "I'm willing to shoot you!"
    • View Profile
Re: AllMovie+ script: Including data for custom fields
« Reply #43 on: July 21, 2010, 02:04:51 am »
Thanks!  I think it's safe to say I couldn't have done that if my life depended on it. ;D

I've updated the first post of this topic to include an updated version. It's modified slightly—to reduce the blank lines between paragraphs from two to one. If anyone is wondering, the same change to the Synopsis/Description has not been make because all of those are a single paragraph.

Offline nostra

  • Administrator
  • *****
  • Posts: 2852
    • View Profile
    • Personal Video Database
Re: AllMovie+ script: Including data for custom fields
« Reply #44 on: July 21, 2010, 02:20:47 am »
Quote
I think it's safe to say I couldn't have done that if my life depended on it. Grin

Yes, it was a bit tricky as you needed an alternative RemoveTags function, but I think now you will be able to solve such problems with ease ;)
Gentlemen, you can’t fight in here! This is the War Room!

Offline rick.ca

  • Global Moderator
  • *****
  • Posts: 3241
  • "I'm willing to shoot you!"
    • View Profile
Re: AllMovie+ script: Including data for custom fields
« Reply #45 on: November 11, 2010, 10:33:58 pm »
Update:
09/24/2010 – 0.1.2.2 – Modified ParseCast procedure to save entire Cast tab to custom memo field, as well as individual actors.
See top post.
« Last Edit: November 11, 2010, 10:38:44 pm by rick.ca »

Offline Ivek23

  • Global Moderator
  • *****
  • Posts: 2713
    • View Profile
Re: AllMovie+ script: Including data for custom fields
« Reply #46 on: November 12, 2010, 07:19:12 am »
Thanks,rick.ca for updates.
Ivek23
Win 10 64bit (32bit)   PVD v0.9.9.21, PVD v1.0.2.7, PVD v1.0.2.7 + MOD


Offline rick.ca

  • Global Moderator
  • *****
  • Posts: 3241
  • "I'm willing to shoot you!"
    • View Profile
Re: AllMovie+ script: Including data for custom fields
« Reply #47 on: July 13, 2011, 08:17:45 am »
The AllMovie site has been replaced by AllRovi. See AllRovi movie script.

 

anything