Answer the question
In order to leave comments, you need to log in
How to run python script from php on xampp which is installed on windows?
there are two files e:\xampp\htdocs\script\test.php and e:\xampp\cgi-bin\test.py
the python program is here c:\Python27\python.exe
test.py
#!/Python27/python
print "Content-type: text/plain\n\n"
print "Hello world"
$python = exec('python e:\xampp\cgi-bin\test.py');
echo "Python is printing: " . $python;
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question