Jump to content
xisto Community
Sign in to follow this  
spy_charly

Mail() Function the mails are sent as SPAM

Recommended Posts

hello guys! i was thinking about the Mail() function coz lately all the mails i send to my friends are send as SPAM and honestly it is a little annoying due to some of them (maybe all of them) use hotmail and the mails they got arrive to the SPAM section, is there anything wrong with my script should i add more headers? and why scripts like the Zen Cart can send mails directly to the Inbox folder?

Share this post


Link to post
Share on other sites

Well, you didn't post anything about the script you are using, so we really don't know what you are sending, but chances are you aren't identifying enough information, so the emails are getting flagged as spam, yes.Some reccomended headers would be "reply-to", "subject", "sender", "to".Format is "Keyword:String\r\n"ie: "Reply-to: myemail@somewhere.sometld\r\n" (no quotes)But you probably know all that...

Share this post


Link to post
Share on other sites

$headers = "MIME-Version: 1.0\n"; $headers .= "Content-type: text/html; charset=iso-8859-1\n";
$headers .= "X-Priority: 3\n";
$headers .= "X-MSMail-Priority: Normal\n";
$headers .= "X-Mailer: php\n";
$headers .= "From: \"".$one."\" <".$two.">\n";


that is my header, do you think it is lacking something?

Share this post


Link to post
Share on other sites

From what I have read, the correct format is "crlf" and requires the "\n" of your headers to read "\r\n" as per above posting.But I might be wrong. The source was 2 years old. (+/-)No doubt someone will correct either you or I if there is a discrepency.

Share this post


Link to post
Share on other sites

so you suggest me to add "\r" to all the lines? so it would fit like?

$headers = "MIME-Version: 1.0\r\n";$headers .= "Content-type: text/html; charset=iso-8859-1\r\n";
$headers .= "X-Priority: 3\r\n";
$headers .= "X-MSMail-Priority: Normal\r\n";
$headers .= "X-Mailer: php\r\n";
$headers .= "From: \"".$one."\" <".$two.">\r\n";


by the way what does "crlf" mean?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.