A great way to never have your PHP script fail
Posted: April 8, 2006 Filed under: WebBasedCron Leave a comment »Hi everyone,
A little while ago I wrote a post about how to prevent your cron job from failing. A comment was posted suggesting the use of the PHP function ignore_user_abort(true). This is a great idea; anyone who is running a PHP script should put this:
ignore_user_abort(true);
as the first line in their script. This way, if your script takes longer than 60 seconds, and WebBasedCron closes the connection, the script will continue to run on your server.
Thanks,
George
WebBasedCron