Cron not passing params to PHP script

前端 未结 3 1624
轻奢々
轻奢々 2021-01-17 03:21

I have a cron job set like

php /home/novinarb/public_html/index.php --uri=\"cron/24satahr\"

but the \'uri\' param doesn\'t get to the php

3条回答
  •  长发绾君心
    2021-01-17 03:52

    Is the php script running at all?

    I suspect you need to provide the full path to php in your crontab line. Even though cron jobs run as you, they don't have any of your login environment set up; this means they don't have your $PATH.

提交回复
热议问题