• Resolved GreenPanda

    (@binarybrew)


    I’m using WP Mail SMTP. The test mail arrives correctly. The WooCommerce emails go to the clients correctly. But any email sent to New Order will send the error message “Undelivered Mail Returned to Sender” and fail with “Host or domain name not found[email protected].

    We’ve tried using different email addresses as recipients to the New Order email. No matter which one we use, WooCommerce will fail to find the host and return the above error. The same email addresses will receive emails correctly from either WooCommerce’s emails directed to clients, or from the SMTP’s test email.

    Even if we leave the field empty to default to the admin email, it still fails with “Host or domain name not found” recipient: [email protected].

    The gist:

    1. SMTP plugin is set up, and is sending test emails correctly
    2. The WooCommerce emails go to the clients correctly.
    3. The same email address, or any other one, including the default admin email, that receive emails correctly as a client or a test email recipient, will return “Undelivered Mail Returned to Sender” error and “Host or domain name not found[email protected].
    4. Deactivating the SMTP plugin produces exactly the same results.
    5. If I add a second email recipient after a comma, the “Array” will get appended only to the second one, letting the first one successfully receive the email.
    6. Adding only a comma, seems to fix the issue and send the email with no “Array” appearing anywhere.

    • This topic was modified 8 months, 1 week ago by GreenPanda. Reason: added information
    • This topic was modified 8 months, 1 week ago by GreenPanda. Reason: Adding info
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Shameem R. a11n

    (@shameemreza)

    Hi @binarybrew,

    In WooCommerce, when you specify multiple recipients, they should be separated by a comma (make sure there is no space). If you add a second email recipient after a comma, the first one successfully receives the email because the function can parse the first email address correctly before encountering the error with the second one.

    Adding only a comma seems to fix the issue because the function can parse the string as an array with a single element, which avoids the error.

    For better assistance, please share a copy of the following:

    • System Status Report: Navigate to WooCommerce → Status. Select Get System Report and then Download for Support. You could copy and paste your reply or share it via Mozilla Community Pastebin and share the link here.
    • Fatal Error log: Share a copy of any fatal error log found under WooCommerce → Status → Logs. You could copy and paste your reply or share it via Mozilla Community Pastebin and share the link here.
    • A screenshot showing your New Order Email settings in WooCommerce. For screenshots, you may use https://snipboard.io – please follow the instructions on that page, then paste the URL in this thread.

    Meanwhile, please review our email sending FAQ for help, troubleshooting steps, and solutions here: https://woo.com/document/email-faq/

    Let us know how that goes. Looking forward to helping you.

    anastas10s

    (@anastas10s)

    We haven’t heard back from you in a while, so I’m going to mark this as resolved – we’ll be here if and/or when you are ready to continue.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘New Order emails only,will always try to send to [email protected] and fail.’ is closed to new replies.