Grabber scripts for MyFilms & AMCupdater (and Beta Tool) (1 Viewer)

Guzzi

Retired Team Member
  • Premium Supporter
  • August 20, 2007
    2,159
    750
    This tool is beta and NOT intended for endusers!

    After some request for it, I post the utility, that is used to create and modify grabber scripts for myfilms.

    Afaik it's initially written by titof, who was supplying grabbers in the past.

    Due to changes on some websites - including imdb - some of the grabbers aren't fully working anymore.

    So if anybody is willing to try, existing grabber could be optimized or new grabbers could be posted here.

    To make it easier, I recompiled the latest sources from sourceforge and made an english translation (original language was french).
    So all tooltips should now give explanations on how to use it - mainly it's a GUI to set grabber options and store them in the grabberscript.

    Usage:
    - Create a new grabberscript (or open an existing one)
    - To add a site, you should firt go to the site and run a search - then copy the URL, that is used for search in the respective field and replace the name of the movie you were searching for with #Search# - if the result also has several pages, replace the pagenumber with #Page#.
    - you then can load this page in the utility with a searchword and get the results in the bottomscreen
    - set the rules to find info on the page - mainly it's about finding strings that identify the positions in the websitesourcecode
    - set the rules for details (the URL to the page you identified on the searchscreen)
    - save the results and test

    Try to use identificationstrings that are not changing too often, otherwise the grabber would fail after even small changes on the website.

    As a start I would recommend to open some of the existing scripts and see, how it's working.

    There are still some bugs in the tool an I just provide it for testing.

    Included in the package are the latest scripts delivered with AMCupdater - new scripts for testing could be posted here.
     

    Attachments

    • Grabber-Interface 5.1.zip
      1.2 MB

    Guzzi

    Retired Team Member
  • Premium Supporter
  • August 20, 2007
    2,159
    750
    • Thread starter
    • Moderator
    • #2
    AW: Grabber scripts for MyFilms & AMCupdater (and Beta Tool)

    It would be nice to get some feedback - I have made some minor updates (mainly better exceptionhandling), but would really like to know if you could use it - and maybe post some updated grabberscripts ;-)
    I am thinking about improvoing the myfilmls internal handling for updates, but makes only sense, if uptodate grabberscripts exist (and there is need for that)
    Thanks,
    Guzzi
     

    z3us

    Portal Pro
    December 4, 2007
    1,047
    123
    46
    Home Country
    Spain Spain
    Is it possible that the help pop-ups dont dissapear or that they stay longer in screen?
    The same for myfilms and AMCu configs
    Thanks
     

    z3us

    Portal Pro
    December 4, 2007
    1,047
    123
    46
    Home Country
    Spain Spain
    FilmAffinity (spanish). Would be great if more than 1 source could be used to obtain data
     

    Attachments

    • MyFilmsAffinity_ES.xml
      4.7 KB

    Guzzi

    Retired Team Member
  • Premium Supporter
  • August 20, 2007
    2,159
    750
    • Thread starter
    • Moderator
    • #5
    AW: Re: Grabber scripts for MyFilms & AMCupdater (and Beta Tool)

    Is it possible that the help pop-ups dont dissapear or that they stay longer in screen?
    The same for myfilms and AMCu configs
    Thanks

    yes, that would be nice ... but I don't know how to do.

    In the code, I set:

    //
    // ToolTip1
    //
    this.ToolTip1.AutoPopDelay = 60000;
    this.ToolTip1.InitialDelay = 500;
    this.ToolTip1.ReshowDelay = 100;

    So this should display the tooltips for 60 seconds.

    If anybody can give me a hint, what to do, I'll be glad to implement...
     

    Guzzi

    Retired Team Member
  • Premium Supporter
  • August 20, 2007
    2,159
    750
    • Thread starter
    • Moderator
    • #6
    AW: Re: Grabber scripts for MyFilms & AMCupdater (and Beta Tool)

    FilmAffinity (spanish). Would be great if more than 1 source could be used to obtain data

    Hi z3us,
    what do you mean with that? you're talking about combining data from different grabberscripts?
    This is currently not possible - I would think about it, if there is some more working grabberscripts available - so if the community provides some, I could check if I can rewrite the grabbercode to support combinations of grabberscripts.
     

    Guzzi

    Retired Team Member
  • Premium Supporter
  • August 20, 2007
    2,159
    750
    • Thread starter
    • Moderator
    • #8
    AW: Re: Grabber scripts for MyFilms & AMCupdater (and Beta Tool)

    Yes, thats what I was talking about

    I have a rough idea for an implementation of that feature ... so let's see if some more scripts will "arrive" -
     

    z3us

    Portal Pro
    December 4, 2007
    1,047
    123
    46
    Home Country
    Spain Spain
    Im trying to make a grabber for imdb.es, but I have problems with actors. There is a regex field, but I dont know what to put there, the tooltip is wrong. How can I use regex?
     

    Guzzi

    Retired Team Member
  • Premium Supporter
  • August 20, 2007
    2,159
    750
    • Thread starter
    • Moderator
    • #10
    AW: Re: Grabber scripts for MyFilms & AMCupdater (and Beta Tool)

    Im trying to make a grabber for imdb.es, but I have problems with actors. There is a regex field, but I dont know what to put there, the tooltip is wrong. How can I use regex?

    Looking in the code it works as follows:

    You can put "#REGEX#" in the "KeyStart" and/or "KeyStop" Windows as first expression, followed by the expression to do search on start / stop point with that expression, instead of standard search "lastindexof".

    You can put "#REVERSE#" on "Replace" window as first expression -> resulting in finding the first instead of last item

    If you put "#REGEX#" in "Replace" following a regular expression, all findings will be replaced by value in "With" window.

    To your question:
    If there is an expression in "RegExp" AND "Replace" starts with "#REGEX#", this results in replacing all matches found with RegExp with replacement value "With".

    Might be easier to look at the codepart to understand (param1 = "Replace", param2 = "With", param3 = RegExp):

    Code:
                                if (param3.Length > 0)
                                {
                                    Regex oRegex = new Regex(param3);
                                    Regex oRegexReplace = new Regex(string.Empty);
                                    System.Text.RegularExpressions.MatchCollection oMatches = oRegex.Matches(strTemp);
                                    foreach (System.Text.RegularExpressions.Match oMatch in oMatches)
                                    {
                                        if (param1.StartsWith("#REGEX#"))
                                        {
                                            oRegexReplace = new Regex(param1.Substring(7));
                                            strTemp = strTemp.Replace(oMatch.Value, oRegexReplace.Replace(oMatch.Value, param2));
                                        }


    hope this helps ....
     

    Users who are viewing this thread

    Top Bottom