What can I do if php cannot execute the exec () function!

Source: Internet
Author: User
What can I do if php cannot execute the exec () function! I used ffmpeg-php extension and needed to execute commands such as exec ("ffmpeg-I 1.amr 1.mp3"). This is to convert the amr format to the MP3 format.

However, the security mode is disabled. The function is also enabled.

Echo'


'.Exe c ('whoam ');

You can run the command to view the server name, but the command is not an external command.

What I use to read a video is:
Extension_loaded ('ffmpeg '); // F: \ mv \ 1.wmv video file path.
$ FfmpegInstance = new ffmpeg_movie ('H: \ ppcall_api \ ps0001.wmv ');

This can be printed, but not converted. Please kindly advise.




Reply to discussion (solution)

Do www-datausers have the execution permission on the files to be processed (ffmpeg,1.amr,1.mp3?


Permission issues: chmod 0775 1.amrand ffmpeg.exe

Perform operations on files to check whether you have operation permissions.

What server? Permission issues, refer to: http://firerain.sinaapp.com/blog/item/5-ffmpeg-mp4

Check whether the absolute path of your file is consistent with the one you spelled out.

Has your problem been solved? I encountered the same problem, but I want to convert the audio. please help me !!!!!!!!!!!!

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.