htmlspecialchars
This commit is contained in:
parent
74b53af924
commit
1f55f2cc55
1 changed files with 1 additions and 1 deletions
|
@ -41,7 +41,7 @@
|
||||||
// write to file
|
// write to file
|
||||||
if (!is_null($_POST["body"]) && strlen($_POST["body"]) != 0) {
|
if (!is_null($_POST["body"]) && strlen($_POST["body"]) != 0) {
|
||||||
$myfile = fopen("posts.txt", "a") or die("Unable to open file! (a)");
|
$myfile = fopen("posts.txt", "a") or die("Unable to open file! (a)");
|
||||||
fwrite($myfile, $_POST["signature"] . ": " . $_POST["body"] . "<br>");
|
fwrite($myfile, htmlspecialchars($_POST["signature"]) . ": " . htmlspecialchars($_POST["body"]) . "<br>");
|
||||||
fclose($myfile);
|
fclose($myfile);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Reference in a new issue