WebsiteBaker Community Forum

WebsiteBaker Support (2.13.x) => General Help & Support => Topic started by: tobyw7 on March 01, 2023, 11:15:56 PM

Title: More troubleshooting contact forms
Post by: tobyw7 on March 01, 2023, 11:15:56 PM
Following on from my last problems with mpform, the problem with the fields showing above the form looks to be related to the anti-spam "nixhier" (not here?) fields being displayed... that could be a template problem as I don't have the problem on my test page https://frantik-web.co.uk/pages/contact-test.php

Either way, when I hit send, I don't receive any emails. Is it using Phpmailer to send? Wondering if my webhost has missed a module from the php config.

I'm using php 8.1
Title: Re: More troubleshooting contact forms
Post by: sternchen8875 on March 02, 2023, 12:42:27 AM
mpform use a own and different way, to send the mail-datas directly to the PHPMailer-Class, but it use the Mail-Settings from WB-Option -> Advanced to send a email via PHPMail or STMP-Mail, that means, if you set there PHPMail, MPForm use PHPMail and if you set it to SMTP, MPForm use SMTP

Use the Switch for the DEBUG-Mode under Server-Settings in the WB-Optionen and try again to send a email.
then you get a report in your error.log with more details
See the X-Button from the TOP-Menu in the WB-Backend

(https://i.gyazo.com/94081c3595e9f8255cc014b3b3b1ba47.png)
Title: Re: More troubleshooting contact forms
Post by: tobyw7 on March 04, 2023, 08:27:44 PM
Thank you. Was missing the "reply to" field being set correctly. The test form worked well so I'll work on the previous conflict with the Anti-Spam and the site template displaying fields that should be hidden.
Title: Re: More troubleshooting contact forms
Post by: ruebenwurzel on March 04, 2023, 09:08:53 PM
to hide the honeypot fields in form add the following to your css:

Code: [Select]
/*** Don't remove the class nixhier, this is required for ASP ***/
.nixhier {
display:none;
}

should normally be part of the frontend.css from modules wich support ASP
Title: Re: More troubleshooting contact forms
Post by: tobyw7 on March 05, 2023, 01:34:47 PM
Vielen Dank!

I added the CSS portion to my template CSS and the honey pot fields are no longer visible and ASP is still enabled. I did see that portion in the module's frontend.css file previously.

The only problem I see now is that I can't use the reload captcha button, and when clicking on the Submit the page refreshes but nothing happens.  On the default template, the reload captcha works and the form submits.
Is the form CSS not loading correctly?

Test form: https://frantik-web.co.uk/pages/contact-test.php
Live form: https://www.frantik-web.co.uk/pages/contact.php

Before adding in the additional CSS from frontend.css to my site CSS, the form did submit!

I can't see any visible errors in using web dev tools :(

This was all working before changes to PHP version (from what I remember, but that may be a red herring).
Title: Re: More troubleshooting contact forms
Post by: tobyw7 on March 05, 2023, 02:25:53 PM
OK - I think I have it fixed.

I checked over the index.php file from the Default theme, and checked over the Enhanced Template Elements https://help.WebsiteBaker.org/en/designerguide/enhanced-template-elements.php, and none of the extras were added. So have added this to my template now and all seems to be working!

Would explain why the frontend.css wasn't registering :)
Title: Re: More troubleshooting contact forms
Post by: ruebenwurzel on March 05, 2023, 07:48:44 PM
Please have a look at the output Filter Settings in your backend. There you can enable or disable the loading of frontend.css from the Modules. It is also possible to add the following lines to your template:

Code: [Select]
<?php register_frontend_modfiles(&#39;css&#39;); ?>
<?php register_frontend_modfiles(&#39;jquery&#39;); ?>
<?php register_frontend_modfiles(&#39;js&#39;); ?>

Did you have this lines in your Template?

I think your problems (even with captcha) have to to with output filter settings and the coding of the index.php of your template. If you load in your template a addtional jquery or js maybe there exists conflicts with the versions from wb.