PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
Basically I'm trying to run ffmpeg inside exec() to take a screenshot of a video, read the saved file and out it to the browser.
I've got the command made up that works just find in ssh with root access, but when I try it within exec nothing happens. Nothing displays, no file is saved like it normally is through the command line, etc.
Why do you think this is? Do I need to enable something? Or CHMOD a directory or something?
Many thanks in advance.
Last edited by phice on Fri Mar 31, 2006 1:13 pm, edited 1 time in total.
Yeah, it may be a permissions thing. That's roughly what it was (that I remember) when I had a similar problem -- different program, but same sort of thing.
I think it all really depends on who owns each or what groups each is. If they are all different, and you can't chown or chgrp them, 0777 is the most open (although fairly dangerous)
What should I CHMOD is really all I need to know (I think).
Should it be the folder that it's writing the screenshot to? The folder ffmpeg is grabbing the videos to? The PHP application itself (if I can find it)? FFMPEG (and it's entire folder?)?
php needs execution rights for ffmpeg; ffmpeg may need rights to write to the destination and read rights for the source (although it may run under php's rights, in which case php would need those); and php will need reading rights for the destination folder (at least.)
It's been a while since I had to fiddle with permissions like this so I could be completely off in space.