Port the code to PHP 8.5.

Replace the short open tags and the removed functions (mcrypt, mysql_error,
salt-less crypt). Decode the reCAPTCHA reply as JSON, turn off mysqli
exceptions, drop stripslashes(), and default missing input values.
Fix the misplaced continue in prune_images().
This commit is contained in:
tim
2026-09-25 21:18:58 +02:00
parent 15e81e17cc
commit 00829a0c0d
23 changed files with 145 additions and 130 deletions
+4 -4
View File
@@ -1,4 +1,4 @@
<?
<?php
// Default to the queue.
if (!isset($_REQUEST['queue']))
$queue = TRUE;
@@ -12,15 +12,15 @@ if (!get_id() && (get_count() > 1))
if ($queue) { ?>
<p>To view already-posted articles, <a href="edit?queue=0">click here</a>.</p>
<? } else { ?>
<?php } else { ?>
<p>To view articles in the queue, <a href="edit?queue=1">click here</a>.</p>
<div class="input" style="text-align: justify">
<form action="" method="get">
<input name="search" type="text" class="input" id="search" maxlength="40" value="<?= $_GET['search'] ?>" />
<input name="search" type="text" class="input" id="search" maxlength="40" value="<?= $_GET['search'] ?? '' ?>" />
<input name="queue" type="hidden" value="0" />
<button type="submit" id="choose" name="action" value="choose" class="inputbutton">Search</button>
</form>
</div>
<? }
<?php }
echo display_stories();
?>