Here is a wierd one.
I have a php script that reads data from a URL and writes it to an xml file. Works great when run from browser.
When I run it as a cronjob it will not exceute. Any other php script I try that reads data just like this will execute fron a cronjob except this one.
Here is the script.
$tide_content=file_get_contents("http://tides.obinet.net");
$local = fopen('tides.xml', 'w');
fwrite($local, $tide_content);
fclose($local);
here is the crontab entry
- 2 * /usr/local/bin/php /home/u4/broadcreek/html/get_tide.php > /dev/null
Run every morning at 2am
Any help.
Stan