Forum Moderators: coopster & phranque

Message Too Old, No Replies

Perl sendmail adding @localhost.localdomain to from name

         

elkay

7:54 pm on Oct 9, 2004 (gmt 0)



When I use the following script, @localhost.localdomain is added to the value of fromaddress when the addressee receives the mail:

open(MAIL, "¦/usr/sbin/sendmail -t");
print MAIL "To: $toaddress\n";
print MAIL "From: $fromaddress\n";
print MAIL "Subject: $formSubject\n\n";
print MAIL "$emailBody\n";
close(MAIL);

Any help in removing that extra verbiage from the sender's address would be very much appreciated.

thanks

Lewis

upside

4:29 am on Oct 10, 2004 (gmt 0)

10+ Year Member



Make sure that your $toaddress and $fromaddress are properly escaped like this:

some\-user\@domain\.com