From 68cdfc181e7c4f398cc2ecd41e3c400083ae0ea8 Mon Sep 17 00:00:00 2001 From: Retro_Guy Date: Wed, 28 Aug 2024 03:51:07 -0700 Subject: [PATCH 01/13] Add Followup-To to post.php. --- Rocksolid_Light/rocksolid/post.php | 34 +++++++++++++++++++++--------- 1 file changed, 24 insertions(+), 10 deletions(-) diff --git a/Rocksolid_Light/rocksolid/post.php b/Rocksolid_Light/rocksolid/post.php index 80d8840..e8d37dd 100644 --- a/Rocksolid_Light/rocksolid/post.php +++ b/Rocksolid_Light/rocksolid/post.php @@ -52,6 +52,11 @@ $logfile = $logdir . '/post.log'; @$references = $_REQUEST["references"]; @$id = $_REQUEST["id"]; +if(isset($_REQUEST['followupto']) && trim($_REQUEST['followupto']) != '') { + $followupto = trim($_REQUEST['followupto']); +} else { + $followupto = null; +} // Load name from cookies if ($setcookies) { if ((isset($_COOKIE["mail_name"])) && (! isset($name))) @@ -129,7 +134,7 @@ $thisgroup = _rawurldecode($_REQUEST['group']); // Is this a reply to an article containing Followup-To? if (isset($_REQUEST['fgroups'])) { - $thisgroup = $_REQUEST['fgroups']; + $thisgroup = preg_replace('!\s+!', ',', $_REQUEST['fgroups']); } $newsgroups = $thisgroup; @@ -306,9 +311,9 @@ if ($type == "post") { if (isset($_FILES["photo"]) && $_FILES["photo"]["error"] == 0) { $_FILES['photo']['name'] = preg_replace('/[^a-zA-Z0-9\.]/', '_', $_FILES['photo']['name']); // There is an attachment to handle - $message = message_post(quoted_printable_encode($subject), $nemail . " (" . quoted_printable_encode($name) . ")", $newsgroups, $references_array, addslashes($body), $_POST['encryptthis'], $_POST['encryptto'], strtolower($name), $_POST['fromname'], null, true); + $message = message_post(quoted_printable_encode($subject), $nemail . " (" . quoted_printable_encode($name) . ")", $newsgroups, $references_array, addslashes($body), $_POST['encryptthis'], $_POST['encryptto'], strtolower($name), $_POST['fromname'], $followupto, true); } else { - $message = message_post(quoted_printable_encode($subject), $nemail . " (" . quoted_printable_encode($name) . ")", $newsgroups, $references_array, addslashes($body), $_POST['encryptthis'], $_POST['encryptto'], strtolower($name), $_POST['fromname']); + $message = message_post(quoted_printable_encode($subject), $nemail . " (" . quoted_printable_encode($name) . ")", $newsgroups, $references_array, addslashes($body), $_POST['encryptthis'], $_POST['encryptto'], strtolower($name), $_POST['fromname'], $followupto); } // Article sent without errors, or duplicate? if ((substr($message, 0, 3) == "240") || (substr($message, 0, 7) == "441 435")) { @@ -476,18 +481,21 @@ if ($show == 1) { echo ''; if ($has_followup) { - echo ''; - echo ''; + echo 'Newsgroups: '; echo ''; - echo '