I can do the following in flash but but HML
i want to write a .txt file from a form
The HTML form is being pointed to the php file "htwrite.php"
and the text area variable "comments"
matched the variable in the php script "$comments"
why does the not work???????
i get a server error
oh and the CHMOD has been changed to 777( access to all permisions )
below are my scripts
thanks
Andrew
___________________________________________________________
<html>
<head>
<title>New Page 1</title>
</head>
<body>
<form method="POST" name="htwrite.php">
<p><textarea rows="11" name="comments" cols="20"></textarea></p>
<p> </p>
<p><input type="submit" value="Submit" name="B1"><input type="reset" value="Reset" name="B2"></p>
</form>
</body>
</html>
___________________________________________________________
<?php
//saves the email text files
$filename = "writeto.txt";
$fd = fopen ($filename, "w");
fputs ($fd, $comments);
fclose ($fd);
?>
<html>
done
</html>
writeing a txt file with php and html problem
Moderator: General Moderators
-
andrew1234
- Forum Newbie
- Posts: 1
- Joined: Tue Feb 04, 2003 5:16 am
- Location: southafrica
- twigletmac
- Her Royal Site Adminness
- Posts: 5371
- Joined: Tue Apr 23, 2002 2:21 am
- Location: Essex, UK