From 36c25f85d101e83e2083f3cb3ad0ad3b77bb6d71 Mon Sep 17 00:00:00 2001 From: spetznas Date: Wed, 17 Jun 2026 18:51:18 +0200 Subject: [PATCH] debugging rsvp-submit.php --- public/rsvp-submit.php | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/public/rsvp-submit.php b/public/rsvp-submit.php index 66e06c5..a4a3e83 100755 --- a/public/rsvp-submit.php +++ b/public/rsvp-submit.php @@ -1,4 +1,19 @@ safeLoad(); + +file_put_contents('/tmp/rsvp-debug.log', "3\n", FILE_APPEND); + require __DIR__ . '/vendor/autoload.php'; use PHPMailer\PHPMailer\PHPMailer; @@ -97,6 +112,7 @@ foreach ($fields as &$field) { $field = mb_convert_encoding($field, 'UTF-8', 'auto'); } +file_put_contents('/tmp/rsvp-debug.log', "4\n", FILE_APPEND); $mail = new PHPMailer(true); try { @@ -193,7 +209,14 @@ EOD; $mail->Body = $body; + file_put_contents('/tmp/rsvp-debug.log', "5\n", FILE_APPEND); + $mail->SMTPDebug = 2; +$mail->Debugoutput = 'error_log'; +$mail->Timeout = 10; +error_log("About to send mail"); $mail->send(); +error_log("Mail sent"); + file_put_contents('/tmp/rsvp-debug.log', "6\n", FILE_APPEND); header('Location: /thank-you/'); exit;