This script combines a page (textwriter.html) and a script (textviewer.php)
<?php
$myfile = fopen ('textthought.txt', 'r') or die ("Can not open file");
while (!feof($myfile)){
$line = fgets($myfile,4096);
print "$line <br>";
}
fclose($myfile);
?>
into one script.
It displays the text in the texthtought.txt file, and creates a form that allows you to add new text to the end of it.
The one change is that the form now calls a new script called textappender.php:
<form action="textappender.php" method="post">