Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

WordPress mail() FROM address

Discussion in 'E-mail Discussions' started by jmartinmds, Jul 27, 2017.

Tags:
  1. jmartinmds

    jmartinmds Member

    Joined:
    Jul 22, 2016
    Messages:
    7
    Likes Received:
    1
    Trophy Points:
    3
    Location:
    Maryland
    cPanel Access Level:
    DataCenter Provider
    I've got several servers set up with dozens of clients, most of which are running WordPress. Lately we've been having an issue with outbound mail. An example of this situation would be something like this:

    example.com is hosted on server1.company.com with the cPanel username examp. The site has a Contact form that sends a notification to the site owner. They use an outside email provider. The form is configured to send from info@example.com and go to admin@example.com with a confirmation sent to the visitor's email address. A visitor fills out the form and clicks Submit. The email message is generated and tries to send. The FROM address in the message is examp@server1.company.com but the envelope says info@example.com.

    Depending on the mail service, some providers are rejecting these emails based on the above mismatch, and if there are spam issues, the domain that ends up getting flagged is server1.company.com, not example.com. How do I configure WHM to use example.com (or whatever is each account's primary domain) as the sender domain rather than server1.company.com?
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    38,658
    Likes Received:
    1,424
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    You'd need to setup the form to use SMTP authentication for sending email as opposed to the PHP mail function. Here's an example of a third-party WordPress plugin used for this purpose:

    Postman SMTP Mailer/Email Log

    Thank you.
     
Loading...

Share This Page