0

I have a script but my server on shared hosting times out after 5 minutes, is there a way to continue script after time-out? The script updates my MySQL database. Do run script for some time and stop then continue automatically but not from the start?

Thanks

4

2 に答える 2

1

実行終了後にスクリプトを自動的に続行する方法はありません。共有ホスティング環境では、しばらくしてからスクリプトを強制終了するのが一般的です。ホスティング会社の wiki / faq でスクリプトの実行が許可されている期間を確認する必要があります。継続的なスクリプトの実行をシミュレートする場合は、自分でコーディングして、何が行われたかを検出し、残りのデータのみを処理する必要があります。

于 2012-12-09T21:35:04.963 に答える
0

Even on shared hosting, you should be able to use set_time_limit (PHP docs)

set_time_limit(0); // infinite
于 2012-12-09T21:32:29.980 に答える