试试打开WEB目录下的文件,看看能不能出结果?会不会权限的原因呢?

解决方案 »

  1.   


    我刚才改了一下,把打开文件并处理的函数去掉,把返回字符串设置为固定的,但php执行exec之后还是返回127。我把命令复制出来直接执行又没问题。
      

  2.   

    string exec ( string $command [, array &$output [, int &$return_var]] )
    To get the output of the executed command, be sure to set and use the output parameter.