I have a piece of code as follows:
$process = proc_open(sprintf('node "%s"', $tmpfile), $desc, $pipes);
Which produces
sh: node: command not found
I tried to set $PATH
in httpd.conf
with SetEnv
, then echo it using getenv('PATH')
. The output actually contains the path to node.
I was able to pass the variable to proc_open
, but I'd like to avoid that because it's someone else's code.
Is there a way for me to give it the correct path?
I am running XAMPP 1.8.2 for Mac OS X.