Keeping automatic emails out of the spam folder
Posted: Mon Dec 14, 2009 9:56 am
Hi
I am trying to set up a PHP mail function that sends a new member a welcome email.
Here's a snippet:
$headers = "MIME-Version:1.0\r\n";
$headers .= "Content-type:text/html;";
$headers .= " charset=iso-8859-1\r\n";
$headers .= "From: email@email.com \r\n";
$mess="Hello ";
$mess.=ucfirst($firstname);
$mess.="<br />";
$mess.="<p>";
$mess.= "You have applied for an account with <b>us.com</b>";
$mess.="</p>";
$mess.="<br />";
$mess.="Click <a href=\"http://www.us.com/confirm_member.php?us ... \">here</a> to confirm your membership";
$re= "You have been sent a message from us.com";
mail( $email, $re, $mess, $headers);
My problem is that the recipient always seems to get the email in his/her email spam folder.
Any advice would be great.
Thanks
ianao
I am trying to set up a PHP mail function that sends a new member a welcome email.
Here's a snippet:
$headers = "MIME-Version:1.0\r\n";
$headers .= "Content-type:text/html;";
$headers .= " charset=iso-8859-1\r\n";
$headers .= "From: email@email.com \r\n";
$mess="Hello ";
$mess.=ucfirst($firstname);
$mess.="<br />";
$mess.="<p>";
$mess.= "You have applied for an account with <b>us.com</b>";
$mess.="</p>";
$mess.="<br />";
$mess.="Click <a href=\"http://www.us.com/confirm_member.php?us ... \">here</a> to confirm your membership";
$re= "You have been sent a message from us.com";
mail( $email, $re, $mess, $headers);
My problem is that the recipient always seems to get the email in his/her email spam folder.
Any advice would be great.
Thanks
ianao