Posts by Pedro • 31 points
1 post
-
3
votes2
answers1461
viewsQ: Add data to a txt file
I have the following code: $msg = "teste"; $myfile = fopen("lista.txt", "w"); fwrite($myfile, $msg."\n"); fclose($myfile); If I change the variable value $msg it opens the file deletes the $msg and…