optimize
This commit is contained in:
parent
6df58cb06c
commit
f50b2817e3
1 changed files with 5 additions and 5 deletions
4
farp.php
4
farp.php
|
@ -4,12 +4,12 @@
|
|||
<body onload="window.location.href = 'https://furp.colean.cc';">
|
||||
|
||||
<?php
|
||||
// write new post to file only if necessary
|
||||
if (!is_null($_POST["body"]) && strlen($_POST["body"]) != 0) {
|
||||
$myfile = fopen("posts.txt", "r") or die("Unable to open file!");
|
||||
$content = fread($myfile, filesize("posts.txt"));
|
||||
fclose($myfile);
|
||||
|
||||
// write new post to file if necessary
|
||||
if (!is_null($_POST["body"]) && strlen($_POST["body"]) != 0) {
|
||||
// concatenate new post to the beginning of the string
|
||||
$signature = "anonymous";
|
||||
if (!is_null($_POST["signature"]) && strlen($_POST["signature"]) != 0) {
|
||||
|
|
Reference in a new issue