$files = array("post", "name", "date");
$post = $_POST["comment"];
$name = $_POST["name"];
$date = date("H:i F j");
foreach ($files as $x) {
$file = fopen("db/$x.txt", "a");
$x = "$" . $x;
fwrite($file, $x);
fclose($file);
}
$files = array("post", "name", "date");
$post