PHP & grep
| From: | Chris Blake | Date: | Tue, 25 Mar 2003 12:34:26 +0000 |
| Subject: | PHP & grep | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-140944@lists.php.net to get a copy of this message | ||
Greetings learned PHP(eople)
I`m using the following to strip values out of a file, however, the file
I`m accessing contains multiple instance of the search criteria, and I
only wanna return the first instance....
I
m just getting an empty variable and cant figure it out...
$criteria = grep "Files :" logs/$file;
I`ve tried other things like 'grep --max-count=1 "Files :"...etc etc,
and that don`t work
Also tried shellexecarg (`grep blah blah blah);......still not working
Any ideas
--
Chris Blake
Office : (011) 782-0840
Cell : 083 985 0379
A chicken is the eggs way of producing more eggs.