Quantcast
Channel: Running a Python script from PHP - Stack Overflow
Viewing all articles
Browse latest Browse all 12

Answer by Niklas Lindblad for Running a Python script from PHP

$
0
0

I recommend using passthru and handling the output buffer directly:

ob_start();passthru('/usr/bin/python2.7 /srv/http/assets/py/switch.py arg1 arg2');$output = ob_get_clean(); 

Viewing all articles
Browse latest Browse all 12

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>