PHP can't run Matlab function

I want run Matlab function from PHP I run this code on MAC, local server using MAMP and Matlab R2016b. this is my php code:
exec ($command = "/Applications/MATLAB_R2016b.app/Contents/MacOS/StartMATLAB computeSIFT.m ");
When i execute that code it's works and Matlab can open 'copmputeSIFT.m' file. But when i want to call Matlab and call 'computeSIFT()' function, there is nothing happened.I think there is no mistake on my code. this is the code:
exec($command = "/Applications/MATLAB_R2016b.app/Contents/MacOS/StartMATLAB nojvm -nodesktop -nodisplay -r \"computeSIFT()\"");
I already search on google, copy paste their code and the result is the same when there is '-r' on my command.Is there some different syntax on matlab R2016b?

回答(0 个)

类别

帮助中心File Exchange 中查找有关 Startup and Shutdown 的更多信息

标签

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by