I have linux bash scripts that run continuously and request a php page. The php page does some magic, and after 500 ms, bash scripts again request the php page, and php does some magic. This is done day after day, but bash sometimes crashes, and that means I need to log in and run the scripts again. No, I'm looking for a solution that is fully managed by php.
I have done the following test (s) but will not work. FILE));
recursiveStopStart(true,$basepath); function recursiveStopStart($mayrun = true,$basepath){ if ($mayrun == true){ sleep(1); exec("C:\wamp\bin\php\php5.3.13\php.exe ".$basepath."/scripts/StopStart.php"); exec("C:\wamp\bin\php\php5.3.13\php.exe ".$basepath."/scripts/TestStopStart.php"); flush(); exit(); } } ?>
StopStart.php are scripts that do magic. TestStopStartphp is the main php page that makes a recursive idea.
I am looking for a solution where I request 1 page, this page calls the magic page and calls itself to start all over again.
The second reason for switching to php is that I can make it platform independent (bash will not work on Windows ...).
Hope someone can help me.
marco source share