• I’m new with WP and need help. We’ve had the site up and running for some time now and lately we’ve notice that new registered users are not receiving email notifications. I’ve tried using Easy SMTP Mail and changed to WP Main Bank to see if the plugin was the issue but still getting the same error message:
    2015-11-01 23:20:49 Connection: opening to smtp-relay.gmail.com:465, timeout=300, options=array (
    ‘ssl’ =>
    array (
    ‘verify_peer’ => false,
    ‘verify_peer_name’ => false,
    ‘allow_self_signed’ => true,
    ),
    )
    2015-11-01 23:20:50 SMTP ERROR: Failed to connect to server: Connection refused (111)
    2015-11-01 23:20:50 SMTP connect() failed. https://github.com/PHPMailer/PHPMailer/wiki/Troubleshooting

    Yesterday, I contacted GoDaddy and they assure me that the email is properly configured for emailing with Google Apps. I also spent 30 minutes with Google and tried several settings as well. Right now SMTP is configured as follows as per Google support:

    SMTP Host: smtp-relay.gmail.com
    SMTP port: 465
    Encryption: SSL
    SMTP Authentication: Yes
    And verified login credentials to authenticate.

    PLEASE HELP! I’ve been at it for 3 days now.

    Thanks.

Viewing 7 replies - 1 through 7 (of 7 total)
  • 1. Turning off SSL verification and allowing self-signed certs is dangerous. Don’t do it, and don’t run code that does it.

    'ssl' =>
    array (
    'verify_peer' => false,
    'verify_peer_name' => false,
    'allow_self_signed' => true,
    ),

    2. Connection refused (111)

    Regardless of what GoDaddy has told you, they block access to Google Apps SMTP. There’s only one solution at GoDaddy and that’s Postman SMTP with the Gmail API option.

    You’ll need to create something called an OAuth 2.0 Client ID, but it’s not that difficult. It certainly won’t take you 3 days.

    Thread Starter nefconline

    (@nefconline)

    Thanks for replying so promptly. So, Postman SMTP is another plugin? Please explain more about the Gmail API option and OAuth 2.0 Client ID.

    I wrote a blog post about Gmail and OAuth 2.0 in February: How to send Gmail from WordPress using SMTP.

    The Web Services API uses port 443, the HTTPS port, to send email past firewalls that block the regular SMTP ports.

    Install the plugin and run the setup wizard and away you go 🙂

    Thread Starter nefconline

    (@nefconline)

    Thanks for replying so promptly. So, Postman SMTP is another plugin? Please explain more about the Gmail API option and OAuth 2.0 Client ID.

    Thread Starter nefconline

    (@nefconline)

    Jason,
    Thanks for the help. Emails are going out setting Authentication to Login. I’ll work on it tomorrow on Grant Permission with Google to use OAuth2.0. I got the following error message and not sure what I have to put for the “redirect URI.”

    Error: redirect_uri_mismatch
    The redirect URI in the request: https://www.nefconline.com/wp-admin/options-general.php?page=postman did not match a registered redirect URI.

    you have to put

    https://www.nefconline.com/wp-admin/options-general.php?page=postman

    for the redirect URI

    Thread Starter nefconline

    (@nefconline)

    I just changed authentication to OAuth2.0 and email is still working perfectly. I recommend Postman plugin to everyone. The Test Connection feature is awesome.
    Thank you Jason.

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘Unable to send emails’ is closed to new replies.