Thank you for the response. I made it through the PHP course but had this type of error several times using either Firefox or Chrome. I found that the output viewport gets out of sync with the index.php content.
I have a PDF showing the typical sequence but was unable to upload the file. Basically
1) Error that does not match index.php content,
2) index.php after Firefox browser refresh (note input seems to have stopped part way through entered code, and
3) Expected results after pasting in what I thought I was looking at for screen shot 1.
I hope this helps you identity cause of these problems. I have a pdf of this if there is a way to provide it for you.