Page 1 of 1

probs in sending mails

Posted: Tue Jun 14, 2005 11:40 am
by sumeet
Hi, I m using apache server in linux andtrying sending of mails by mail() in php but the problem is the mails are going into bulk mail on yahoo i guess its becoz yahoo is reading mail frm apache@localhost .. is there any option by which i can avoid redirection of mails in bulk mail by adding something in headers ??

Posted: Wed Jun 15, 2005 12:04 am
by anjanesh
You can add the header

Code: Select all

$headers .= 'From: yourname@yourdomain.com' . "\r\n" .
to specify the From Address.
mail()
It does goto the bulk folder if HTML content is added to it.

Code: Select all

$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
// And message contains a lot of HTML tags.