I'm trying to run a python script from php with
$res = '';
exec('./home/Desktop/Scripts/fetch_matches.py', $res);
My python file starts with #!/usr/bin/python
and has exec rights. For now I only have a print in there but it's not working(var_dump($res)
gets me an empty array). What's missing?
Also, if I'll have different methods in that script, how would I call them?