Checking exec() runs successfully or not

前端 未结 4 534
小鲜肉
小鲜肉 2020-12-07 20:13

I have been trying to let know know if the exec() command in php executes successfully or not so i can echo certain messages accordingly. I tried the following

4条回答
  •  广开言路
    2020-12-07 20:53

    i do work for me

    for system linux and lang:php,laravel

    exec('/usr/bin/tesseract 2.png out1 -l '.$lang,$output,$error);
               return (!$error)? "success":"Error";
    

提交回复
热议问题