Page 1 of 1

Cron job in php

Posted: Tue Feb 28, 2012 3:47 am
by sumeetbiswal
Hi All,
I am a php developer.I am doing a project which requires some functionality to run automatically in server.So i tried cron job in php.i am very new to cron job in php.I have no control panel password to do it.
i want to write some code in php for cron job and upload it in server throgh FTP.
i want a file runs in every 5 mins every day.
my server API is CGI script.
please anybody help me how to do it and say me the step for cron job for running a php file .

Re: Cron job in php

Posted: Tue Feb 28, 2012 5:12 am
by Celauran
You'll need access to the crontab. Generally, cPanel will give you access to that if the host allows it. If you have shell access, you could call 'crontab -e' from the command line, but that seems far less likely.

Re: Cron job in php

Posted: Tue Feb 28, 2012 6:44 am
by sumeetbiswal
Thanks i was also tried for shell access .but not success . plz tell me how to use shell access and how i get it.

Re: Cron job in php

Posted: Tue Feb 28, 2012 6:50 am
by Celauran
You'll need to contact your hosting provider.

Re: Cron job in php

Posted: Tue Feb 28, 2012 10:38 am
by temidayo
There are services that will help you run the file at interval. You can google running cron jobs with cron tab
or see this article : http://www.dscripts.net/2010/07/27/run- ... n-support/