How to run a php function after certain time without using cron -
i have block of code , want run after time intervals, after every 3 seconds. if required result should die otherwise request sent after 3 seconds. idea php.
thanks in advance help
you can sleep in loop:
while (true) { $result = dosomething; if (resultisgood) { break; } sleep(3); } if don't want keep browser waiting, can ignore_user_abort() solutions on google.
Comments
Post a Comment