Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Posted on
- exec() with Linux
November 5, 2007, 5:45 pm
rate this thread
distribution. Running vlc from a shell works perfectly, but I have a lot of
problems if it is executed with function exec:
$command = "vlc";
I get an error message in apache log file:
VLC media player 0.8.6c Janus
 skins2 interface error: Cannot open display
 skins2 interface error: cannot initialize OSFactory
Error: Unable to initialize gtk, is DISPLAY set properly?
What is the DISPLAY to set ? Please consider I am a newbie in Linux.
Same as before but running vlc with --daemon option. Now seems that vlc
process is running and I don't get any error message in apache log file, but
it does not record any input stream.
Is there anybody that can help me ?
Re: exec() with Linux
You are trying to run a program that needs to talk to the display. DISPLAY
is an environment variable that tells the graphics system (X11) where to
send output. You won't be able to run the program from a web server if it
You are probably on the right track, but it's going to be hard for anyone
to help without knowing that program. Here's an idea: From a shell window,
do "unset DISPLAY", then try to get the program to do what you want. Once
you can do that, you can try it from the web server.