Hi,
I have a simple form:
Quote:
<FORM METHOD="POST" ACTION="myscript.php">
Speech Box input:
<INPUT TYPE="text" NAME="mytext" SIZE="50">
<INPUT TYPE="submit">
<INPUT TYPE="reset">
|
and a simple php script:
Quote:
<?PHP
$filename = "mytext.txt";
$text = $_POST['mytext']; #
$fp = fopen ($filename, "w");
if ($fp) {
fwrite ($fp, $text);
fclose ($fp);
echo ("File written");
}
else {
echo ("File was not written");
}
?>
|
If I input:
I get:
in the resulting txt file.
Can someone tell me what is causing this?
Thanks,
-OG-