问题
i have a problem in Apache ant all commands are working in ssh client putty but when i try to run in shell_exec it gives error
sh: ant: command not found
is there is any permission using in shell_exec
i have root access to the server
回答1:
Does PHP honour your environment PATH? you may need to qualify the path to the executable. Refer to this post for more path/shell info: PHP exec $PATH variable missing elements
来源:https://stackoverflow.com/questions/10834134/apache-ant-working-in-root-not-in-shell-exec