you can use fopen() function to open the file and write to it using fwrite().
remember to open the file with 'a+' argument which will open it in append more, which writes the new entry to the file at the end of it.
to delete an entry, you will need to do bit more of a work. first read the entire file in to an array using file() function, then run a for loop to get the required username, and delete it. then open the file with 'w' mode (re-writing the entire file, NOT appending) and re-write the entire array back to it.
lookup the php.net for further information for the above mentioned functions.
hope this helps...
may be someone else has a better idea .. 🙂
Daarius...