Page 1 of 1

Searching in a text file

Posted: Wed Nov 12, 2008 3:26 am
by ShadowWolf
Ok, I have a php file which insert in a txt file values entered by a user through some forms. What I need to do now is to perform a search through this text file and come up with every string that matches the results.
Example:
Text File Content

Daniel Shepard 23 Abbey Road London Student
Mike Harris 43 Downing Street London Bricklayer
Diane Mulder 32 Downing Street London Teacher

If I write Downing Street in the search form it should give me

Mike Harris 43 Downing Street London Bricklayer
Diane Mulder 32 Downing Street London Teacher

What Can I Do? I tried to read documentation on php.net, but I didn't come up with the soluton. Thanks in Advance.

Re: Searching in a text file

Posted: Wed Nov 12, 2008 3:37 am
by aceconcepts

Re: Searching in a text file

Posted: Wed Nov 12, 2008 3:37 am
by VladSun