PHP Execution cmd Command solution

Source: Internet
Author: User
PHP Execute cmd command
How to execute the following system commands in PHP:
D:\matlab\r2012a\bin>matlab-r Matrixcompute

I tried using the following code:

Header ("content-type:text/html; Charset=utf-8 "); Set file Encoding format
Echo ("Open matlab ... ");
EXEC ("D:\matlab\r2012a\bin>matlab- R matrixcompute");
?>


The result is only output: open matlab ...
The system does not open the MATLAB program.

Excuse me, what is the reason? (Safe mode is off)
------to solve the idea----------------------
You've written the wrong order!
D:\MATLAB\R2012a\bin \matlab-r Matrixcompute

Please note: external commands executed by PHP are run in the background, do not appear in the user interface, and do not respond to user interaction
------to solve the idea----------------------
Matlib is not a tool to output c/cpp code, and then use PHP to expand the package layer.
And Matlib should be able to open the TCP service bar, so PHP and matlib between the socket communication on the line.
  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.