Sterc / FormIt

A dynamic form processing Snippet for MODX Revolution
https://docs.modx.com/current/en/extras/formit
33 stars 58 forks source link

Email hook fails to grab `emailsender` system setting #67

Closed osabate closed 8 years ago

osabate commented 8 years ago

Unless specified system reports the following error on the Error Log:

[FormIt] An error occurred while trying to send the email. SMTP Error: data not accepted.SMTP server error: DATA END command failed Detail: 5.7.60 SMTP; Client does not have permissions to send as this sender SMTP code: 550

sdrenth commented 8 years ago

Hi @osabate,

Could you provide some more information about this issue?

osabate commented 8 years ago
  1. I believe FormIt 2.2.7.
  2. Something like this: [[!FormIt? &hooks=email,redirect &validate=username:blank,confirmemail:blank,year:blank,email:required &redirectTo=971 &emailTpl=Support &emailFrom=do-not-reply@domain.com &emailSubject=Support &emailTo=support@domain.com ]]
  3. I believe I resolved the issue by setting the parameter value under System Settings instead of in the snippet since any values set on `emailsender would be ignored.
joeke commented 8 years ago

@osabate I think this is more of an issue with the SMTP settings than with FormIt. Is the do-not-reply@domain.com address allowed to send mail via your SMTP? If not, then perhaps set this e-mailaddress as the emailReplyTo and a valid e-mailaddress (that is allowed by your SMTP) as the emailFrom parameter.

osabate commented 8 years ago

This is an old issue I had. I ended up resolving it and I'm pretty sure it turned out to be a SMTP misconfiguration.

Thanks!