I need to find a specic line of text, from several lines of text
So, I have a text file with several lines of text, eg:
JOHN
MIKE
BEN
*BJAMES
PETE
I read that contents into an array, with each line of text, placed into a seperate element of the array.
I then tested each element of the array, to find the line that starts with, say: *B
ie:
if ( preg_match( "/^\*(B)/",$contents[$a] ) )
why dosnt that work ?