Details
-
Type: Bug
-
Status: Done/Fixed
-
Priority: Minor
-
Resolution: Fixed/Completed
-
Affects Version/s: 2.2.0
-
Fix Version/s: 2.2.1
-
Component/s: Core CiviCRM
-
Labels:None
Description
Currently the "Send Test Email" function in CRM/Admin/Form/Setting/Smtp uses the logged in users email address as the FROM and TO for the test email. This is not a reliable test for some cases (esp if host has tight restrictions on allowable FROM email values). Also, the FROM and TO values used are not shown to the user which can make it hard to debug.
1. Modify the function to use the default FROM email address as the sender.
2. Prefix the following to the status message shown by postProcess (for both success and failure cases):
"Sending test email. FROM: $fromEmailAddress TO: $toEmailAddress <br />"
I've also added text to the SMTP error message in CRM_Utils_Mail so that folks know to check the FROM email used against their hosts rules:
'The FROM Email Address configured for this feature may not be a valid sender based on your email service provider rules.'
... and centralized the error message function in to CRM_Utils_Mail::errorMessage