php8 fix
This commit is contained in:
6
README
6
README
@@ -1,4 +1,4 @@
|
||||
PHPCSV Guestbook version 0.99.8
|
||||
PHPCSV Guestbook version 0.99.9
|
||||
|
||||
Simple php guestbook/feedback form with csv file data storage.
|
||||
|
||||
@@ -17,9 +17,9 @@ Features:
|
||||
- Feedback form mode
|
||||
|
||||
Working example:
|
||||
http://zlaxyi.soundragon.su/gb
|
||||
https://is3.ussr.win/zlaxyi/gb
|
||||
|
||||
PHPCSV Guestbook requires PHP 5.0 or higher version.
|
||||
PHPCSV Guestbook requires PHP 8.0 or higher version.
|
||||
|
||||
Installation:
|
||||
|
||||
|
||||
22
index.php
22
index.php
@@ -175,29 +175,29 @@ function AddEntryView() {
|
||||
$captchanumber22=rand(0, 9);
|
||||
$_SESSION["captcha"]=md5(base64_encode(($captchanumber11.$captchanumber12)+($captchanumber21.$captchanumber22)));
|
||||
echo "<form action=index.php method=post enctype=\"multipart/form-data\">\n";
|
||||
echo " ",$Titles["Name"],": <input type=text name=\"name\" value=\"",$Values["name"],"\" maxlength=255> (",$Titles["Required"],")<br>\n";
|
||||
if ($GBcityfield) echo " ",$Titles["City"],": <input type=text name=\"from\" value=\"",$Values["from"],"\" maxlength=255><br>\n";
|
||||
if ($GBlinkfield) echo " ",$Titles["Link"],": <input type=text name=\"link\" value=\"",$Values["link"],"\" maxlength=255><br>\n";
|
||||
if ($GBemailfield) echo " ",$Titles["Email"],": <input type=text name=\"email\" value=\"",$Values["email"],"\" maxlength=255> ($Titles[NotPublic])<br>\n";
|
||||
echo " ",$Titles["Name"],": <input type=text name=\"name\" value=\"",$Values["name"] ?? false,"\" maxlength=255> (",$Titles["Required"],")<br>\n";
|
||||
if ($GBcityfield) echo " ",$Titles["City"],": <input type=text name=\"from\" value=\"",$Values["from"] ?? false,"\" maxlength=255><br>\n";
|
||||
if ($GBlinkfield) echo " ",$Titles["Link"],": <input type=text name=\"link\" value=\"",$Values["link"] ?? false,"\" maxlength=255><br>\n";
|
||||
if ($GBemailfield) echo " ",$Titles["Email"],": <input type=text name=\"email\" value=\"",$Values["email"] ?? false,"\" maxlength=255> ($Titles[NotPublic])<br>\n";
|
||||
if ($GBsubjectfield) {
|
||||
echo " ",$Titles["Subject"],": <input type=text name=\"subj\" value=\"";
|
||||
if(isset($_POST["reply"])) echo $_SESSION["reply"][7];
|
||||
else echo $Values["subj"];
|
||||
else echo $Values["subj"] ?? false;
|
||||
echo "\" maxlength=255><br>\n";
|
||||
}
|
||||
if ($GBcategoryfield) {
|
||||
echo " ",$Titles["Category"],": <select name=\"category\">";
|
||||
foreach($GBcategoryfield as $Category) {
|
||||
echo " <option value=\"$Category\"";
|
||||
if ($Values["category"]==$Category) echo " selected=\"selected\"";
|
||||
if ($Values["category"] ?? false==$Category) echo " selected=\"selected\"";
|
||||
echo ">$Category</option>";
|
||||
}
|
||||
echo "</select><br>\n";
|
||||
}
|
||||
if ($GBfield1) echo " ",$Titles["Field1"],": <input type=text name=\"field1\" value=\"",$Values["field1"],"\" maxlength=255><br>\n";
|
||||
if ($GBfield2) echo " ",$Titles["Field2"],": <input type=text name=\"field2\" value=\"",$Values["field2"],"\" maxlength=255><br>\n";
|
||||
if ($GBfield3) echo " ",$Titles["Field3"],": <input type=text name=\"field3\" value=\"",$Values["field3"],"\" maxlength=255><br>\n";
|
||||
echo " ",$Titles["Text"],":<br>\n <textarea name=\"text\" wrap=virtual cols=50 rows=5 maxlength=$GBtextlenght>",$Values["text"],"</textarea><br>\n";
|
||||
if ($GBfield1) echo " ",$Titles["Field1"],": <input type=text name=\"field1\" value=\"",$Values["field1"] ?? false,"\" maxlength=255><br>\n";
|
||||
if ($GBfield2) echo " ",$Titles["Field2"],": <input type=text name=\"field2\" value=\"",$Values["field2"] ?? false,"\" maxlength=255><br>\n";
|
||||
if ($GBfield3) echo " ",$Titles["Field3"],": <input type=text name=\"field3\" value=\"",$Values["field3"] ?? false,"\" maxlength=255><br>\n";
|
||||
echo " ",$Titles["Text"],":<br>\n <textarea name=\"text\" wrap=virtual cols=50 rows=5 maxlength=$GBtextlenght>",$Values["text"] ?? false,"</textarea><br>\n";
|
||||
if ($GBupload) {
|
||||
echo " <label for=\"file\">".$Titles["FileUpload"]."</label>\n";
|
||||
echo " <input type=\"hidden\" name=\"MAX_FILE_SIZE\" value=\"".$GBfilesize."\" />\n";
|
||||
@@ -373,7 +373,7 @@ function EntriesView() {
|
||||
foreach($SearchResult as $n=>$Entry) $Entries[$n]=$Entry[1];
|
||||
} else echo $Titles["NoResult"].": '",$_POST["serachq"],"'.<br>\n";
|
||||
}
|
||||
if (($GBpagination>0)&&(count($Entries)>$GBpagination)) {
|
||||
if ((!$DataStatus=="empty")&&($GBpagination>0)&&(count($Entries)>$GBpagination)) {
|
||||
$Entries=array_reverse($Entries);
|
||||
if (isset($_GET["page"])) switch ($_GET["page"]) {
|
||||
case $Titles["First"]:
|
||||
|
||||
Reference in New Issue
Block a user