I want to call the python file from php using exec() but the output always is blank, and i do not know what is the problem, can anybody help me?
This is php code
<?php
exec("D:\python27\python.exe C:\xampp\htdocs\hi.py");
?>
This is python code
print "Content-Type: text/HTML"
print
print"""
<html>
<body>
<h2>Hello World!</h2>
</body>
</html>
"""
I can run the python file along and the browser will display hello world!, however when i using exec() in php, it would not work.