[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
Re: Sendmail and the extra .com
- From: David Whitehurst <dlwhitehurst comcast net>
- To: redhat-list redhat com
- Subject: Re: Sendmail and the extra .com
- Date: Tue Apr 29 21:23:31 2003
Sorry, Jeff. I didn't think about the HTML mail message. I have been
developing on Windows way too long. I used to be a "real" C-programmer on
UNIX (what's that? huh?). Ok, I'll try again. I am using RedHat 7.0. and I
somehow got to a sendmail.cf file via linuxconf. I haven't quite figured
the m4 preprocessor out yet.
I am using mod_perl with apache for my web server in my my home.
http://www.piratepetesoftware.com
Here's the Perl that I call as a test. I want to mail a download client a
text mail with a link to the download file. I'll CGI get the IP of that
person and the web page asks for their mail and name.
Code ...
#!/usr/bin/perl -w
#print "Hello";
my $location_of_sendmail = '/usr/sbin/sendmail';
my $mailingfrom = "webmaster piratepetesoftware com";
my $to = "dlwhitehurst\ comcast net";
my $subject_line = "Test Mail";
my $message = qq{"Hello"};
send_mail($mailingfrom, $to, $subject_line, $message);
sub send_mail {
my ($from, $to, $subject, $messagebody) = @_;
my $flags = "-t";
$mail_program = $location_of_sendmail;
$mail_program .= " $flags";
open (MAIL, "|$mail_program") || die "Could Not Open Mail Program: $!";
print MAIL <<__END_OF_MAIL__;
To: $to
From: $from
#Reply-to: $from
Subject: $subject
X-Mailer: Any Mail 1.0
Content-type: text/plain
$messagebody
__END_OF_MAIL__
close (MAIL);
} # End of send_mail
# Print out HTML
print <<"END_OF_HTML";
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html lang="en">
<head>
<title>TreasureFind v1.1.0.0©</title>
<meta name="Author" content="David L. Whitehurst">
<meta name="Copyright" content="©2003 PiratePete Software">
<meta name="Date" content="04-22-2003">
</head>
<body bgcolor="#FFFFFF">
<center>
<h3><font face="Arial, Helvetica, sans-serif">Thank You!</font></h3>
</font>
</center>
<p>
<blockquote>
<font face="Arial, Helvetica, sans-serif"><font size="2">
You will receive an email momentarily that contains a URL link to the
TreasureFind
download. Please remember to send your comments about the application.
Your feedback is
very important to future enhancements of this product.
<a href="http://68.48.223.222" target="_parent">Return to Homepage.</a>
</font>
</blockquote>
</body>
</html>
END_OF_HTML
My website is pointed to 68.48.223.222 which is my Comcast identifying IP.
My wireless router forwards 80, 21, 23, 110 ports to this linux (my server).
I am using piratepetesoftware.com as the domain in the sendmail.cf and I
list 127.0.0.1, 68.48.223.222, and 192.168.1.100 in my /etc/hosts I can
send mail to my comcast mailbox dlwhitehurst comcast net but the header
lists piratepete com piratepetsoftware com as the sendee. Deep in the mail
I know that the real reply is to apache piratepetesoftware com (I see this
in the header). I'm stumped why the dot-com is getting stuck on any user I
put in the Perl code above. Also, if I use ELM and send a message from the
piratepete account on the linux box to my outlook (dlwhitehurst comcast net)
I get piratepete thevirtualdomain correctly. (No dot-com after the
piratepete.
???? Thanks for any reply
David
David L. Whitehurst Senior Web Developer dlwhitehurst comcast net
----- Original Message -----
From: "Jeff Kinz" <jkinz kinz org>
To: <redhat-list redhat com>
Sent: Tuesday, April 29, 2003 7:21 PM
Subject: Re: Sendmail and the extra .com
> On Tue, Apr 29, 2003 at 05:44:02PM -0400, David Whitehurst wrote:
> > Can anyone tell me why I cannot remove the .com from my mailing address.
If I send a mail e.g. from piratepete piratepetesoftware com using Perl,
sendmail keeps putting .com on the user. e.g
piratepete com piratepetesoftware com I cannot figure it out. Any
suggestions as to where or why sendmail is adding .com?
>
> Hi Dave, please set your mailer to wrap text at 72 chars wide.
>
> You will need to add some details about your situation. For example what
> Perl tools are you using?
>
> Perl is a language and many, many people have implemented SMTP, POP or ISP
> mail libraries in Perl, Which ones are you using and what calls are you
> making?
>
> Are you sure that you are connecting to sendmail?
>
> What version of RedHat are you using?
>
> Are you trying to do a direct connection to the addressee or are you using
> smarthost and routing all email through your ISP's SMTP relay?
>
>
> My first guess without any further info is that you might be making a call
> incorrectly, but that would only be a guess.
>
>
> >
> --
> Jeff Kinz, Open-PC, Emergent Research, Hudson, MA. jkinz kinz org
> copyright 2003. Use is restricted. Any use is an
> acceptance of the offer at http://www.kinz.org/policy.html.
> Don't forget to change your password often.
>
>
>
> --
> redhat-list mailing list
> unsubscribe mailto:redhat-list-request redhat com?subject=unsubscribe
> https://listman.redhat.com/mailman/listinfo/redhat-list
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]