- fclose: documentation ( source)
- fwrite: documentation ( source)
- fopen: documentation ( source)
<?php
if(isset($_POST["submit"])){
if($_POST['formsend']==1){
if($_POST["user"]!="" && $_POST["email"]!="" && $_POST["message"]!=""){
$file=fopen("database.txt","a+");
fwrite($file,$_POST["user"]." ".$_POST["email"]." ".$POST["message"]."\r\n");
fclose($file);
}
}
}