$content = "Name: $name\n Surname: $surname\n"; $filename = "user.txt"; $createfile = fopen($filename, 'w'); fwrite($createfile, $content); fclose($createfile);
How to write data to a file. PHP code example
More
lil-code© | 2022 - 2024
Go Top
$content = "Name: $name\n Surname: $surname\n"; $filename = "user.txt"; $createfile = fopen($filename, 'w'); fwrite($createfile, $content); fclose($createfile);