Asked 7 years ago
28 Nov 2016
Views 1412
lain

lain posted

how to set cron in cpanel ?

How to set cron in Cpanel ? its Linux shared server : LAMP , and i dont know much php but i have file named "cron.php" want to set it cron so it run twice a day .
so after login at Cpanel i got "cron job" section


i select their once per day so its auto selected some timing parameter but now question is that what to enter in command input box . because i dont know any command to set cron .

Mitul Dabhi

Mitul Dabhi
answered Nov 30 '-1 00:00

simply write
php file_physical_path
suppose
if you filename "cron.php" is in the folder /home2/shareddomain/public_html/ than write following in the cron command

php /home2/shareddomain/public_html/cron.php	


how to get physical path of the directory which contain cron file , i not good at php - lain  
Nov 28 '16 07:06
Post Answer