Am trying to run a controller action as a cron job, but it is giving me the message, "could not open input file"
To do the above, i used this link, http://bakery.cakephp.org/articles/view/calling-controller-acti开发者_开发问答ons-from-cron-and-the-command-line....
But not working for me, I also tried to place the cron dispatcher in /app/webroot, but still not working for me.
thanks...
PHP cannot load your cron_dispatcher.php. Make sure your cron entry is correct, i.e. points to the correct full path of your PHP file. Also make sure that you have your access rights correctly. It's possible that the file exists but that when PHP runs under cron, it is not allowed to read the file.
PS: Have you considered using CakePHP's Shell functionality instead of this dispatcher? It was designed for CLI use.
Call direct your action
wget http://www.example.com/homes/my
in my action wirte your code
set in cpanel ....
精彩评论