Page 1 of 1

Honeypot Email Blocking

Posted: Tue Nov 28, 2023 11:43 pm
by gofrank
If the "Honeypot" feature is enabled on a form in WB19, is there any additional code to be added by the user to actually enable blocking? The help file and tutorial indicates the Honeypot triggered email "can be blocked"...but does WB actually do the blocking, or is there another step on the user's side?

The reason I ask is that in looking at the PHP code, the Honeypot selected variable doesn't appear to be examined during validation.

Re: Honeypot Email Blockinig

Posted: Wed Nov 29, 2023 7:05 am
by Pablo
You do not have to add any code yourself.

The generated code will look something like this:

Code: Select all

 if (!empty($_POST['phone']))
   {
      $error .= "Spam detected.\n<br>";
      throw new Exception($error);
   }

Re: Honeypot Email Blocking

Posted: Wed Nov 29, 2023 12:03 pm
by gofrank
You're right! I missed the exception when looking at the code. When that happens, it's a sign I've spent too much time at the computer and need a good night's sleep.

Thanks, Pablo.