Mail code

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
bhanu
Forum Commoner
Posts: 46
Joined: Thu Nov 05, 2009 4:25 am

Mail code

Post by bhanu »

How to send mails in inbox not a spam in php code
User avatar
Jonah Bron
DevNet Master
Posts: 2764
Joined: Thu Mar 15, 2007 6:28 pm
Location: Redding, California

Re: Mail code

Post by Jonah Bron »

You really can't dictate where the user's email client puts the email. The best you can do is to make sure the From header is the same as the actual email server you use. Beyond that, you'll just need to tell them to check their spam box.
josh
DevNet Master
Posts: 4872
Joined: Wed Feb 11, 2004 3:23 pm
Location: Palm beach, Florida

Re: Mail code

Post by josh »

Set up spam assassin and have it add scoring to the email headers. It will tell you what common attributes are being detected (there are 100s of these factors, rDNS not pointing back, you are on the SBL block list, EHLO of the wrong host name, too much HTML to text ratio, use of all caps, use of certain key words, certain key word densities, high link to text ratio, high image to text ratio, etc.. etc.. all these factors compound on you certain ones worse than others)

Most common issue is EHLO http://en.wikipedia.org/wiki/Anti-spam_ ... O_checking

Its a setting in sendmail and other MTAs (mail transfer agents). It defaults to localhost in sendmail which WILL get you flagged as spam.
bhanu
Forum Commoner
Posts: 46
Joined: Thu Nov 05, 2009 4:25 am

Re: Mail code

Post by bhanu »

Thanks for replies...
Post Reply