I try to execute this PHP command :
$result = exec("sudo python /home/pi/test.py",$output, $ret);
var_dump($result);
echo "<br>";
var_dump($output);
echo "<br>";
var_dump($ret);
This command works perfectly on a Linux Terminal but with the PHP it doesn't work.
Here the result on the PHP page :
string(0)
array(0) { }
int(9)
I verified the process with ps -ef
, nothing appears.