Hi,
I’ve changed the Frontmatter content on my contact form and I’m getting an error when the form is submitted.
I added this:
email: null
subject: ‘[Site Contact Form] {{ form.value.name|e }}’
body: ‘{% include ‘‘forms/data.html.twig’’ %}’
This is the error I get after submitting the form:
“Argument 1 passed to Grav\Plugin\EmailPlugin::buildMessage() must be of the type array, null given, called in /var/www/vhosts/the-abuzzers.com/httpdocs/user/plugins/email/email.php on line 79”
What am I doing wrong? (i’m new on Grav )
Thanks for your help.
Greetz,
djdakta
Hi,
I solved this issue by myself and I’m proud about it.
(Damn… What a frustration it was.)
The issue was caused by the identation of the Frontmatter content in my contact form.
I did not respect the indentation after the ‘process’ paragraph.
After fixing this issue I got an other server error after submitting the form with this message:
“stream_socket_enable_crypto(): Peer certificate CN=*.ikoula.com' did not match expected CN=
mail.the-abuzzers.com’”
I solved this by changing the email plugin configuration not to use the TLS encryption and go over port 25 instead of port 587.
I’m so glad!
Oh well done, I was going to suggest using a real email address instead of “null”
Hey hughbris,
I’ve changed that but it did not help though, I’m glad I finally found what the issue was and that the contact form is now working as a charm! :-)