A great way to never have your PHP script fail

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:


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.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s