Re: infinite loop problem
| From: | Wico de Leeuw | Date: | Tue, 08 Aug 2000 16:03:17 +0000 |
| Subject: | Re: infinite loop problem | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-10719@lists.php.net to get a copy of this message | ||
At 11:36 8-8-00 -0400, Erb, Maria wrote:
hi, I'm using preg_match for pattern matching and am trying to search a large file. The following code if (preg_match ("/wcb/,$myFile,$matches)) {if (preg_match ("/wcb/", $myFile, $matches)) {
do this } results in an infinite loop. The file never ends! Is there a way when reading a file in to set an EOF marker? Or is there another way to set a flag with preg_match at the EOF? thanks! Maria Maria B. Erb Web Developer Keene State College 603-358-2340 mail address: MS 2707 / CMIT 229 Main Street Keene, NH 03435 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net For additional commands, e-mail: php-general-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net