Menu

processstats mod success

DPF
2005-09-25
2013-04-16
  • DPF

    DPF - 2005-09-25

    I modified processstats to use my TZ/DST mod.  To test I configured processstats to start working at, what I thought would be, 30 minutes after the start of the games.  I further modified it so that if the force=1 GET parameter was used, it would work right away.
    I have processstats.php scheduled to run every 3 minutes.  At 15 minutes after the start of the first game, all my matchups still showed a score of 0.  I manually ran processstats with the force=1 parameter set, and when I refreshed the matchups (games.php) page, the score were updated.  I then watched until 29 minutes after the game started and the scores did not change.  At 30 minutes after the game started (when I expected my mod to allow processstats to start running) the scores started getting updated!
    To use this mod, you must either:
    1.  use my mods
    a. use my mod'd offlconfig.php (or just edit yours to require_once userfunctions.php)
    b.  use my userfunctions.php
    c.  use my mod'd processstats.php
    d.  optional (I think, these mods add refresh buttons, and fix the NFL schedule gametimes displayed, which shouldn't be necessary to fix processstats.php):  use my mod'd header.php
    Or:
    2.  incorporate my mods into your own installation
    a.  look at userfunctions.php, and pull out and use the javascript and php scripts for TZ/DST
    b.  look at processstats.php, and pull out and use the mod'd section concerning gametime
    c.  optional (I think, see above ): look at header.php and pull out and use the mod's re TZ/DST

    All my mod'd files are available for download at http://home.comcast.net/~michele.flynn/offlmods.html.

    And, again, I have not done extensive testing of any of this, so use at your own risk.

     
    • twardenb

      twardenb - 2006-08-03

      Hello -  I would love to get these mods but it appears that flynnstone's site no longer exists.
      Does anybody still have them?

      Thanks,
      Tony

       
      • Brad Schwie

        Brad Schwie - 2006-08-03

        Tony,

        Michele's page still works.  You have to remove the period at the end of the link:

        <a href="http://home.comcast.net/~michele.flynn/offlmods.html">Try this link instead.</a>

        I should take a look at this again for incorporating into OFFL.  I don't know why I didn't before.  Probably just too busy...

        Brad

         
    • twardenb

      twardenb - 2006-08-03

      Awesome! thank you.

       
      • Brad Schwie

        Brad Schwie - 2006-08-03

        Tony,

        Please let me know how her patch works for you and if you have time while you're doing it, please document what things you had to do differently than what she posted on her site.  I'd love to hear about it as it makes my life easier when updating the code.

        Brad

         
    • twardenb

      twardenb - 2006-08-03

      will do.

      Hope to give it a shot tonight.

       
    • twardenb

      twardenb - 2006-08-03

      the changes were easy to make and the instructions - though could be merged - were easy to follow.

      I did have to re-install the 2006 Schedule Fix.

      I had to make a userimages directory under /images

      I lost of course any customized work that I did to the replaced files but a diff against the backed up files made that easy to correct.

      I see style changes as well

      The only thing that seemed to break - and I haven't tried everything yet - was the forum. I sed the phorum code that is in the offl forum and now the link is broken. But, when I comment out this section:

      /**
      // auto refresh for games.php page
      require_once("offlconfig.php");
              if($_SERVER['SCRIPT_NAME'] == "/games.php")
                      {
                      if(!empty($GAMES_REFRESH_TIME)) //first check to see if it's even set
                              {?> <META HTTP-EQUIV="refresh" CONTENT="<?php echo $GAMES_REFRESH_TIME; ?>"> <?php
                              }
                      }

      */
      // auto refresh for matchups.php page

      in the lib/usersfunctions.php it works again.

      * there is now an image for the forum to be displayed called easteregg that could be changed to something else - just check the error_logs and you will see the path that is missing *

      I have no idea what this section does and why it would affect the forum link but here is the error:

      [Thu Aug  3 17:58:34 2006] [error] PHP Fatal error:  main(): Failed opening required '/offlconfig.php' (include_path='.:/usr/local/lib/php') in /usr/local/apache/vhosts/www.XXXXXX.com/htdocs/www/lib/userfunctions.php on line 42

      anyone?

       
    • twardenb

      twardenb - 2006-08-04

      Got it.

      this line:

      require_once("offlconfig.php");

      needed to be:

      require_once($DOC_ROOT . "/www/offlconfig.php");

      So,

      You will have to re-insert any custom code into thpse files as would be expected.

      Add a usersimage directory under images/ and forum/images if you use forum - if you want to display the pictures that are configured in userfunctions.php

      re-install the 2006 schedule patch

      change line 42 in userfunctions.php as shown above

      Now, if I had some stats to test we could write this off. But the refresh button and settings look to be working and are not throwing errors.

      The only other thing I did not see working was Michele had scrolling messages on some pages but they are not working for me. No errors are being thrown. I will look into this over the weekend.

      All in all pretty painless and hopefully works when stats are available. Will we get them for preseason to test?

       
      • Brad Schwie

        Brad Schwie - 2006-08-07

        I think I tried running the stats engine during the preseason last year and it didn't work for me.  I didn't really expect it to, as OFFL extensively relies on the season start control date for many functions.  This is probably more than just a quick tweak of the code, but I could be wrong.

         
    • DPF

      DPF - 2006-09-19

      Brad, I was moving my pages off my wife's page, and I f*k'd up, overwriting my log page listing what my mods did.  and, of course, comcast (says) they don't backup personal webpages, so I lost the log.  Sigh...

      Still have the mod'd files though, in case anyone wants them.  New location is http://spookaloo.home.comcast.net/

      The old location will redirect to the new for awhile.

      Hope you're having a great fantasy season!

       
      • Brad Schwie

        Brad Schwie - 2006-09-20

        I think I might have a copy of this that I can post on my site.  I'll dig into it and report back.

        Otherwise, the data may have been cached by Google.

         

Log in to post a comment.