RE: [PHP] shell_exec with pipes

From: Date: Tue, 11 Nov 2003 17:15:32 +0000
Subject: RE: [PHP] shell_exec with pipes
Groups: php.general 
Request: Send a blank email to php-general+get-169190@lists.php.net to get a copy of this message
[snip] > $var=shell_exec("/usr/local/bin/mplayer -identify -frames 0 > /tmp/pitstop.mpeg 2>/dev/null\| grep ID_LENGTH \| cut -d \"=\" -f 2"); [/snip] $var=shell_exec("/usr/local/bin/mplayer -identify -frames 0 /tmp/pitstop.mpeg 2>/dev/null | grep ID_LENGTH | cut -d \"=\" -f 2"); Try just escaping the quotes, pipes should be OK IIRC.

« previous php.general (#169190) next »