How do you get a Cronjob executing a PHP script to run longer than 30 seconds?

前端 未结 6 1941
梦谈多话
梦谈多话 2021-01-20 18:10

How can I rewrite this into a cron that will run every day for longer than 30 seconds? Also, do I need to edit the .htaccess or php.ini file in the

6条回答
  •  抹茶落季
    2021-01-20 18:36

    Use this syntax to start php:

    php -c /path/to/another/php.ini /this/is/the/file/cron.php
    

    Then you can specify a different timeout (or no timeout) in a different php.ini file.

提交回复
热议问题