Re: Extracting string from shell_exec call

From: Date: Wed, 28 Jul 2004 06:58:33 +0000
Subject: Re: Extracting string from shell_exec call
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-192076@lists.php.net to get a copy of this message
C.F. Scheidecker Antunes wrote:
Hello all. I have a function that executes the unzip command.
..
What I want to do is to extract the value(s) after inflating, so that I can check what was extracted from the zip.
You can do so with regular expresson but a more simple aproach may be to use the split command the split up the output from the shell command into an array. then you can do a string comparision on each element - less elegent but easier to master if you are not familiar with regular expressions. -- Raditha Dissanayake. ------------------------------------------------------------------------ http://www.radinks.com/sftp/ | http://www.raditha.com/megaupload Lean and mean Secure FTP applet with | Mega Upload - PHP file uploader Graphical User Inteface. Just 128 KB | with progress bar.

« previous php.general (#192076) next »