I don't know the code, but I would assume you could do the following:

  1) read the file into an array, with each line as an element
  2) search the element that has the line you're looking for...probably a
keyword
  3) remove that element from the array
  4) implode the array
  5) rewrite the file with the same name, but with the content of the new
array.

  Array keywords:  shift, push, pop, etc..

 I hope that helped.


__________John Monfort_________________
_+-----------------------------------+_
     P E P I E  D E S I G N S
       www.pepiedesigns.com
"The world is waiting, are you ready?"
-+___________________________________+-

On Wed, 16 May 2001, Tarrant Costelloe wrote:

> Does anyone know what the code is, if you wanted to specify a specific line
> in a file to delete and also to wipe clean the entire file?
>
> Thanks in advance!
>
> Taz
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to