1. Please take a little time for this simple survey! Thank you for participating!
    Dismiss Notice
  2. Dear Pleskians, please read this carefully! New attachments and other rules Thank you!
    Dismiss Notice
  3. Dear Pleskians, I really hope that you will share your opinion in this Special topic for chatter about Plesk in the Clouds. Thank you!
    Dismiss Notice

Mail send via PHP is sent as 'anonymous@mydomain.com' - How to change 'anonymous' ??

Discussion in 'Plesk for Linux - 8.x and Older' started by AlexB@, Mar 2, 2006.

  1. AlexB@

    AlexB@ Guest

    0
     
    Where can I change the setting, that emails sent via PHP 'mail' function are not sent with 'anonymous@mydomain.com' in the header.
     
  2. tobtob

    tobtob Guest

    0
     
    Good Question. Thats the way it works for me too. Also, a lot of mail sent via PHP from my plesk machine gets blocked at my mail server because it cliams to be infected with a virus. Here is the message in th avirus log : File(s) are INFECTED [[Outlook 'CR' Vulnerability]: 0] )

    I'll be watching this thread for a solution.I don't often see things solved here though. A lot of dead threads.
     
  3. damargon

    damargon Guest

    0
     
    <?php

    $stremail = "receipt@hisdomain.com";
    $asunto = "Newsletter";
    $sbody = "message of the email";

    $headers = "MIME-Version: 1.0\n";
    $headers .= "Content-type: text/html; charset=iso-8859-1\n";
    $headers .= "From:Your name company<webmaster@yourdomain.com>\n";
    $headers .= "Reply-To:Webmaster<webmaster@yourdomain.com>\n";
    $headers .= "X-Priority: 1\n";
    $headers .= "X-MSmail-Priority: High\n";
    $headers .= "X-mailer: DAUMED\n";

    mail($stremail, $asunto, $sbody, $headers, "-fwebmaster@yourdomain.com");

    ?>
     
Loading...