Unable to run matlab script from php

I can happily trigger Matlab script from command line using exec() command but when it comes to doing this via PHP I dont get any success.
exec("\'C:\Program Files\MATLAB\R2019a\bin\matlab.exe\' -nosplash -nodesktop -r \'run('G:\MATLAB_Scripts\sample.m')\" 2>&1");
I have checked php.in file where disable_function =____
I'm lost for what to do now, Google hasnt given me much help apart from unresolved posts to various forums.
Thanks in advance!

1 Kommentar

Guillaume
Guillaume am 21 Mai 2019
Sounds like a PHP problem more than a matlab problem, so you'd be better off asking on a PHP forum.
However, note that the matlab license typically does not allow you to run scripts on a web server, so even if you find a solution you may not be allowed to use it.

Melden Sie sich an, um zu kommentieren.

Antworten (0)

Kategorien

Mehr zu Loops and Conditional Statements finden Sie in Hilfe-Center und File Exchange

Produkte

Version

R2019a

Tags

Kommentiert:

am 21 Mai 2019

Community Treasure Hunt

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

Start Hunting!

Translated by