well, either make sure $search contains the entire page
or, you have an array fo lines, loop thru it line by line
foreach ($lines as $line)
eregi( ... )
AFAIK, eregi will match *everything* and dump it all into
$matches (at least that's the behaviour that pregs follow,
i dont use eregs)
---
Scott Hurring
Systems Programmer
EAC Corporation
[EMAIL PROTECTED]
Voice: 201-462-2149
Fax: 201-288-1515
> -----Original Message-----
> From: Robert [mailto:[EMAIL PROTECTED]]
> Sent: Friday, June 07, 2002 4:46 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] very simple eregi / loop question
>
>
> How would you loop though a file ( or web page) and get all
> of a certain
> thing. I'm trying to strip stuff out of tables, but I have
> only managed to
> get the first of what I'm searching for. My expression is
> eregi("[0-9]{1,3}.[0-9]{1,3}.[0-9]{1,3}.[0-9]{1,3}", $search,
> $content);
> which does the job, but how do I apply that to get all of
> that from the
> page?
>
> thanks
>
> --
>
>
>
>
> ------------------------------------------------------------
>
>
> Robert Packer
> Programming and Design Associate
> 814-944-1108
> [EMAIL PROTECTED]
> -- NRC Online --
>
> ------------------------------------------------------------
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php