shell-exec

Can't execute python script from PHP (apache2)

Can't execute python script from PHP (apache2) Question: I want to execute Python script from PHP file using apache2 on my macos. I am able to execute simple python script like: From PHP: $result = shell_exec(“python /Library/…./example.py ‘$name’ ‘$email’ ”); var_dump($result); To Python import sys x = sys.argv[1] y = sys.argv[2] print(“name: ” + x …

Total answers: 2