How to run the PHP script at scheduled time

后端 未结 4 902
梦谈多话
梦谈多话 2020-11-30 15:17

I need to run a php script at the scheduled time daily to update some fields in database and to send automated email. How I can do this?

Is it possible to write so

4条回答
  •  猫巷女王i
    2020-11-30 15:57

    You should use a Cron job to do it. Check out the examples on the Wikipedia page.

    The Cron Job should call a script using the php executable that runs the necessary task.

提交回复
热议问题