Hello ! I have a problem with the cronjob file on my droplet ! I have uploaded a website on my server ( ubuntu with lamp installed) , that site is now running on a domain on a shared hosting with Cpanel and I want to transfer it to my droplet but first I need to be sure that the script it works on my new server so I don’t have any problem with my site script , but when I try to run manually the cron job script on my browser by typing http://mydropleip/cron_job.php I see a blank page where is write this : #!/usr/bin/php which is not an normal thing , and the script is not working ! The crontab is working on my server I checked it and it works ! The only think that is not running is that cronjob script ! I think I need to install something else on the server but I don’t know what ? That cronjob is crucial for my website ! I really don’t know what I am doing wrong ! Thanks in advance !
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Thank you for the answer kamaln7 ! I made it executable but still not running I don’t get any error when I run it manually only that it doesn’t doing his job ! The strangest thing is that everything was just fine till I moved my site here :( !
Do you get any errors when you try to run it manually from the command line? Please post the crontab line.
Try marking the file as executable:
The cronjob.php it supposed to get a list from an xml API and it works just fine on the shared hosting that I used till now but here just don’t work and I can’t figure out where is the problem ! Thank you !
If crontab is working, then it must be something within your cron_job.php. What is it suppose to do? Or what is the cron_job.php? Need more information…