throw an alert if no data is entered
This commit is contained in:
parent
634df4995f
commit
67f13ba616
1 changed files with 2 additions and 0 deletions
2
farp.php
2
farp.php
|
@ -23,6 +23,8 @@
|
||||||
$myfile = fopen("posts.txt", "w") or die("Unable to open file!");
|
$myfile = fopen("posts.txt", "w") or die("Unable to open file!");
|
||||||
fwrite($myfile, $content);
|
fwrite($myfile, $content);
|
||||||
fclose($myfile);
|
fclose($myfile);
|
||||||
|
} else {
|
||||||
|
echo '<script>alert("Please draw something.")</script>';
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
|
|
||||||
|
|
Reference in a new issue