Forum Moderators: coopster

Message Too Old, No Replies

receiving emails in hotmail.com addresses

hotmail.com email addresses don`t receive mail sent from php mail()

         

Hop_Hop

12:08 am on Jul 14, 2006 (gmt 0)

10+ Year Member



My script is :

$to = "slbzlatv@hotmail.com";
$subject = "You've got mail!";
$message = "Hello someone.";
$headers = "From: admin@example.net\n"; // I suggest you try using only \n
$headers .= "MIME-Version: 1.0\n";
$headers .= "Content-type: text/html; charset=iso-8859-1\n";
$headers .= "Return-path: me <admin@example.net>\n";
$headers .= "X-Priority: 1\n";
$headers .= "X-MSmail-Priority: High\n";
$headers .= "X-mailer: PHP";

mail ($to, $subject, $message, $headers, "-f admin@example.net");

-----
Qmail-send tells me this :

@4000000044b6ceb7340da53c new msg 427543
@4000000044b6ceb7340f2fc4 info msg 427543: bytes 420 from <admin@example.net> qp 8885 uid 33
@4000000044b6ceb738f2fcb4 starting delivery 754: msg 427543 to remote slbzlatv@hotmail.com
@4000000044b6ceb738f346ec status: local 0/10 remote 1/255
@4000000044b6ceb935a661f4 delivery 754: success: 65.54.244.8_accepted_message./Remote_host_said:_250__<20060713225229.8884.qmail@mail.example.net>_Queued_mail_for_delivery/
@4000000044b6ceb935a901d4 status: local 0/10 remote 0/255
@4000000044b6ceb935aa3a54 end msg 427543

and slbz@hotmail.com doesn`t receive any email ...

I underline that if i send from outlook express it works

[edited by: coopster at 3:55 pm (utc) on July 14, 2006]
[edit reason]
[1][edit reason] generalized domain [/edit]
[/edit][/1]

webdudek

9:06 am on Jul 14, 2006 (gmt 0)

10+ Year Member



in some cases hotmail treats emails sent with mail() as spam.
check your spam folder.
you can use phpmailer to solve this problem.
it's a great open source script for sending emails.

barns101

3:15 pm on Jul 14, 2006 (gmt 0)

10+ Year Member



How would Hotmail know that an email was sent using mail()? (Except with the header "X-mailer: PHP" of course.)

In my experience HTML formatted emails can get penalised because the majority of spam is sent in that format; your email address could be blacklisted; your server IP address could be blacklisted; your server may not have valid PTR records (which can cause Hotmail to simply ignore your emails).

coopster

3:42 pm on Jul 14, 2006 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



It all comes down to the headers. Servers receiving mail aren't aware how an email was composed (unless there are custom headers sent as barns101 mentioned). phpmailer, PEAR mail classes, and many other classes invoke the PHP mail() function. It all depends on what headers you are sending out with your email. What the developers of the phpmailer and PEAR packages have done is reviewed the RFCs and wrapped PHP code around the specs to deliver quality mail headers along with your message.