Results 1 to 10 of 14

Thread: Server "from" e-mail address

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    rlhanson's Avatar
    rlhanson is offline Master Glow Jedi
    Join Date
    Aug 2007
    Location
    Chapman, Kansas
    Posts
    531

    Default Server "from" e-mail address

    Is there any way to change the from e-mail address that displays in message headers processed through a domain?

    Example: user@server.name.net; on behalf of Company Name

    I think this is a server response as all my clients feedback forms have this entry. Is there any way to have it say info@domainname.com instead?
    Thank you,
    Lynne Hanson
    RL Hanson-Online

  2. #2
    Matt's Avatar
    Matt is offline GlowHost Administrator
    Join Date
    Jan 2005
    Location
    Behind your monitor
    Posts
    6,251

    Default

    That behavior generally comes from if your scripts are using the PHP mail() function. Using the PHP mail() function to send email sometimes has options in the script admin to set the correct headers, but most scripts lack this functionality.

    If the script has an option to send email using SMTP instead of PHP, use that option and it will send for the desired address instead of user@some.hostname.com

    You will need to configure a real email address in your control panel, then supply the script with the correct username and password for that email address the same way you would setup your email program.
    Last edited by Matt; 10-11-2010 at 07:50 PM.
    Send your friends and site visitors to GlowHost and get $125 plus bonus!
    GlowHost Affiliate Program | Read our Blog | Follow us on X |

  3. #3
    rlhanson's Avatar
    rlhanson is offline Master Glow Jedi
    Join Date
    Aug 2007
    Location
    Chapman, Kansas
    Posts
    531

    Default

    Thanks for the response!

    Would you happen to have an example on setting these headers in a php form processor?
    Thank you,
    Lynne Hanson
    RL Hanson-Online

  4. #4
    sergey is offline Master Glow Jedi
    Join Date
    Aug 2005
    Posts
    472

    Default

    If you want to send e-mails using PHP mail() function and change the from e-mail address then you may create a php.ini file in a directory where you are sending e-mails from and set the below variable in it:

    Code:
    sendmail_path="/usr/sbin/sendmail -t -i -f your-mail@domain.com"
    youre-mail@domain.com will need to be replaced with your address.
    Last edited by Matt; 10-13-2010 at 09:34 PM.

  5. #5
    charlesh's Avatar
    charlesh is offline Master Glow Jedi
    Join Date
    Aug 2006
    Location
    Atlanta, GA - better than you imagined it would be.
    Posts
    189

    Default Exim Config

    We were talking about this earlier, Lynne, and got me curious. I've noticed "On behalf of arjuna.harmonmediagroup.com" appearing in my client's sendmail generated messages. I saw that this was an Exim config thing. Is this to help get messages to the recipients without ending up in a spam box. Such as mail.hosteddomain.com coming from the sendmail on the server?

    Would / should you change this behavior?

    Charles

  6. #6
    Matt's Avatar
    Matt is offline GlowHost Administrator
    Join Date
    Jan 2005
    Location
    Behind your monitor
    Posts
    6,251

    Default

    The option you are referring to is from WHM > Exim Configuration:

    Set the Sender: Header when the mail sender changes the sender (-f flag passed to sendmail)
    Always set the "Sender:" header when the sender differs from the actual sender. Unchecking this will stop "On behalf of" data in Microsoft® Outlook, but may limit your ability to track abuse of the mail system.
    My interpretation of the description of this setting, checking it off in your WHM will set the -f header for you when using the PHP mail() function so that it does not need to be set in php.ini. I do not think that it actually works though.

    You can try enabling it in your WHM if it is not set already then retry your form processor and let us know how it goes.
    Send your friends and site visitors to GlowHost and get $125 plus bonus!
    GlowHost Affiliate Program | Read our Blog | Follow us on X |

Similar Threads

  1. Replies: 7
    Last Post: 09-23-2008, 04:14 PM
  2. Share a PHP coder - a "timeshare" solution that saves you $$$
    By Matt in forum General Announcements
    Replies: 0
    Last Post: 03-20-2006, 02:35 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14