i have wriiten a form and a php script and hope once i type anything in the text field text e.g if i type "reset" in the textfield and the word"reset" would produce in a text file ??
however i keep getting the error msg
Parse error: parse error, unexpected T_VARIABLE in /home/free-users/ill2000m/try.php on line 8
below shows the coding for my form (the file is called try.html)
<html>
<title>yeah</title>
<body>
<form action="try.php" method="POST">
type here: <input type="text" name="name" size="20" />
<input type="submit">
</form>
</body>
</html>
and my php script shows below (the file is called try.php)
<html>
<title>form</title>
<script language ="php">
$text = $_POST["totext"]
$topost = "<p>$text</p>"
$fp5 = fopen("textfile.txt", 'a');
fwrite($fp5, $topost);
fclose($fp5);
</script>
<body>
yes yes
</body>
</html>


