Jump to content


Popular Content

Showing content with the highest reputation on 06/30/2019 in all areas

  1. 1 point

    Auto Update Currencies

    If the code only looks at the time of day, and doesn't keep track of the day on which it was last run, it's not very good code. Anyway, if you can't run a proper "cron" job, look at "poor man's cron" examples that do track when the last time something was run was, and kick off the run if enough time has passed. Such code would be started from some place in osC such as application_top.php. I think there may be a poor man's cron in one of the mass mailing add-ons, where you don't want to dump an avalanche of emails on the system, but just dribble out a few at a time, then wait for the next run of osC that's a few minutes later. I don't know if anyone has generalized a PMC to run arbitrary modules at arbitrary times/dates, but that would be a great feature for osC. Perhaps you would be better off if you worked with your host to understand what their limitations are on cron jobs. It's understandable that they want to keep out-of-control scripts off their servers, but cron is a necessary part of any non-trivial website. You got burned once by not understanding what they allowed, but that doesn't mean you can't craft a cron job that they will allow.
  2. 1 point

    Auto Update Currencies

    The code compares the current hour to what you have in the setting. If you have it set to 10 and you never login to your admin before 10, the script will never run. Also, it only runs when you are on the index,php page of admin. So sometime before 10 go to ...com/admin/index.php and it should run. You can run it manually by going to ...com/admin/auto_update_currencies.php If that works, then it is a time or page issue as described. If it doesn't, then it is probably due to the links for currencies. Try updating the currencies manually in the currencies section of admin to see if the code will do it.