removing lines from array

From: Date: Sun, 22 Jul 2001 23:35:46 +0000
Subject: removing lines from array
Groups: php.general 
Request: Send a blank email to php-general+get-59107@lists.php.net to get a copy of this message
I an trying to figure out how to remove lines from a text file from within an array. I fill the array with this $recordsarray = file ("../auto/records"); The lines I what to remove have this in them $remove = "schopf.net "; What I need is how to loop through this array and pull out the lines that have what is in the $remove variable. Then I will write the array to a temp file and thin copy it back to the records file This is a small sample of the file I what two remove lines from mx - schopf.net High www.schopf.net ptr - readinggenius.tv 207.200.75.55 24 a - time-management-by-higher-productivity.com 207.252.75.55 24 ptr www speedreading123.com 207.200.75.55 24 ptr - mindbodyspirit123.com 207.200.75.247 24 a www schopf.net 207.252.75.242 24 soa - schopf.net dns1.northwesthost.com:dns2.northwesthost.com:rkurth@www.northwesthost.com:10800:3600:604800:86400 - Best regards, Richard mailto:rkurth@pacifier.com

« previous php.general (#59107) next »