Posted By

rubinip on 12/16/08


Tagged

phprunforevertimertimeoutinterval


Versions (?)

Who likes this?

1 person have marked this snippet as a favorite

ginoplusio


Run PHP Script forever


 / Published in: PHP
 

  1. <?php
  2. ignore_user_abort(); // run script in background
  3. set_time_limit(0); // run script forever
  4. $interval=60*15; // do every 15 minutes...
  5. do{
  6. // add the script that has to be ran every 15 minutes here
  7. // ...
  8. sleep($interval); // wait 15 minutes
  9. }while(true);
  10. ?>

Report this snippet  

Comments

RSS Icon Subscribe to comments
Posted By: MMDeveloper on December 16, 2008

how would you kill it?

You need to login to post a comment.