<?php
if(isset($_POST['submit'])){
$file="get.php";
$open = fopen($file, "a+"); //open the file, (get.php).
fwrite($open, "Name: " .$_POST['user'] . "/n"); //print / write the name.
fwrite($open, "Colour: ". $_POST['color'] . "/n"); //print / write the colour.
fclose($open); //close the opened file
echo "Log File Entry Had Been Made";
}
?>
但输出被写入get.php作为 - &gt; / nName:发布的名称/ nColour:发布的颜色/ n 如果你有时间请帮助,谢谢大家。
答案 0 :(得分:3)
字符是“\ n”,而不是“/ n”。只需更换它,它就可以工作。