<?php
$File = "YourFile.txt";
$Handle = fopen($File, 'a');
$Data = "Jane Doe\n";
fwrite($Handle, $Data);
$Data = "Bilbo Jones\n";
fwrite($Handle, $Data);
print "Data Added";
fclose($Handle);
?>
This should add these two names to the end of the file, so our file now contains four names:
John Henry
Abigail Yearwood
Jane Doe
Bilbo Jones



