I am trying call an executable of MATLAB code from PHP. Within MATLAB code I used fprintf(1, '123 456') to export result. This works when I run my MATLAB executable in console, but I cannot get results in PHP call $rt = exec('myMatlabCode.exe', $result). PHP $result is empty. Does anyone have some clue? Thanks.
exec
is usually in the disabled functions list. check your php.ini
http://uk1.php.net/manual/en/ini.core.php#ini.disable-functions
http://uk1.php.net/function.exec
Theres also another parameter at the end, Have a look at the value of that
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.