Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Nov 2006
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    exec and shell_exec

    Hello,

    I'm new to running exec commands on php.
    I've had ffmpeg installed on my server, at /usr/local/bin/ffmpeg (a cmd line video decoder). It's a linux server, running php5.
    From looking around the internet, I came up with this code to run it:

    <?php
    shell_exec("/usr/local/bin/ffmpeg -i /home/urieilam/www/work/video/subbed.mov -ab 56 -ar 22050 -b 500 -r 15 -s 320x240 /home/urieilam/www/work/video/test.fla");
    ?>

    It's not working, no error message.
    I'm running the code from within /home/urieilam/www/work/video/, is that the mistake? Do I have to add some code to move back to the root directory? If so, what is it?
    I've also tried "exec" instead of "shell_exec", hasn't worked either.

    Unfortunately, I don't have direct Shell/SSH access, so placing the php code in the root would be a problem (i think).

    Anyone know about this stuff? The documentation I've been able to find is pretty lacking.

    Thanks
    Uri

  • #2
    Senior Coder NancyJ's Avatar
    Join Date
    Feb 2005
    Location
    Bradford, UK
    Posts
    3,174
    Thanks
    19
    Thanked 66 Times in 65 Posts
    can ffmpeg make flas? I thought it was flvs?
    There is an $output parameter that you can use with exec() to store the response from the command - this might help you in debugging.

  • #3
    New to the CF scene
    Join Date
    Nov 2006
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts
    sorry, mistyped the code.
    it was "...flv" (in the acutal script)


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •