function write (){
$file = 'people.txt';
$current = file_get_contents($file); // Open the file to get existing content
if ($current === false) {
return false;
}
$current .= "John Smith\n"; // Append a new person to the file
return file_put_contents($file, $current) !== false; // Write the contents back to the file
}