PHP shell exec command -


i using windows application tesseract, long story short ocr application runs through command.

after installing application used command test , works fine using line:

tesseract text.png out 

it practically gets image , outputs text file out.txt

i changed directory , accessible everywhere.

now problem comes when using php using code follows:

echo exec("tesseract text.png out 2>&1", $output); var_dump($output); 

and time instead of getting file saying tesseract not recognized!

this output:

operable program or batch file. c:\wamp64\www\prestashop\ocr\ocr.php:12: array (size=4)   0 => string '' (length=0)   1 => string 'c:\wamp64\www\prestashop\ocr>tesseract text.png out'    (length=51)   2 => string ''tesseract' not recognized internal or external command,' (length=65)   3 => string 'operable program or batch file.' (length=31) 

can me please!?

thanks

i have answer. don't know why had restart pc work php


Comments

Popular posts from this blog

magento2 - Magento 2 admin grid add filter to collection -

Android volley - avoid multiple requests of the same kind to the server? -

Combining PHP Registration and Login into one class with multiple functions in one PHP file -