========================================================== CONTACT FORM + reCAPTCHA v3 - drop-in file Bella Vista Farm (15 November 2026) ========================================================== WHAT THIS IS Your contact form lives in contact.php on the server, and it has never left the server, so I could not rewrite it. Instead you get a small wrapper that sits in front of it: contact.php <- NEW: checks Google's score, then runs yours contact-core.php <- your ORIGINAL contact.php, renamed Nothing inside your original form is changed or deleted. It still does exactly what it did before; the wrapper only adds one thing before it runs and one thing into the page it prints. In this zip: contact.php the wrapper (goes into public_html) recaptcha.php the helper (already uploaded - identical) blocked-page-preview.html what a blocked sender sees (just a preview) READ-ME-FIRST.txt this file ---------------------------------------------------------- SET-UP - in this exact order ---------------------------------------------------------- 1. cPanel > File Manager > public_html 2. Right-click contact.php > Rename > type: contact-core.php (nothing is broken in this moment; the wrapper is not there yet, so the old form is simply not reachable for a few seconds) 3. Upload contact.php from this zip into public_html - If cPanel asks, choose Overwrite. There is no contact.php left, so it should just arrive. 4. Make sure recaptcha.php is still in public_html (it is - your checker found it at /home/bellavis/public_html/recaptcha.php) 5. Open https://bellavistafarm.co.za/contact.php You should see the normal form. Press Ctrl+U and Ctrl+F "render=" - the Google script should be there now. 6. Send yourself a real test message. It should arrive as usual. That is all. No code editing, no line numbers. ---------------------------------------------------------- IF SOMETHING LOOKS WRONG ---------------------------------------------------------- You need the contact page working at all times, so undoing is designed to take five seconds: delete contact.php rename contact-core.php back to contact.php The old form is instantly back, exactly as it was. If the page says "One set-up step is still missing", step 2 was skipped - rename contact.php to contact-core.php and reload. ---------------------------------------------------------- WHAT WAS TESTED (with a mock of a PHP form, before shipping) ---------------------------------------------------------- [ok] normal visit -> form shown, Google script + token field added directly above the Submit button [ok] submit, no token -> blocked, 403, no email sent [ok] submit, fake token -> blocked, 403, no email sent [ok] submit, good score -> form's own code runs, email sent, redirect [ok] submit, good score but a field empty -> the form's own error message still appears, the token field is re-inserted so the retry is not blocked [ok] contact-core.php missing -> clear message instead of a broken page What I cannot test from outside: your real form's behaviour after the wrapper hands over, because the form's code is not visible to me. If the form still sends mail normally after step 5-6, everything is fine. If it does not, undo (above) and send me contact-core.php - I will wire the reCAPTCHA straight into it instead of around it. ---------------------------------------------------------- AFTER IT WORKS ---------------------------------------------------------- - google.com/recaptcha/admin: this key pair's secret was typed into a chat, so delete the pair, create a new one, and replace the two lines at the top of recaptcha.php. Check bellavistafarm.co.za is listed under the key's domains. - Delete recaptcha-status.php from public_html if it is still there. - If real customers ever get blocked, lower BV_RECAPTCHA_MIN_SCORE in recaptcha.php from 0.5 to 0.4.