Sending mails from PHP

Discussion in 'Programming' started by alise, Apr 6, 2007.

  1. #1
    Hi,

    I don't know where to start, but will try to describe the situation!

    I have a dedicated server and a site which sends out the verification email when user registers. The saddest part is that the email goes right into the spam folder for Gmail and Yahoo and doesn't arrive to Hotmail accounts at all (it's simply ignored without reporting any errors)!

    So, first I was thinking that there's something wrong with my PHP code, tried different approaches with header information, different classes - it's all the same! Added reverse DNS, and SPF records for my domain as well, checked with dnsstuff.com - no red flagged things are reported there!

    When I gave up on trying different things with PHP scripts I decided to try emailing from Mozilla Thunderbird... from the same my domain's email address! Tried that in two ways - one time with the outgoing server specified - mail.mydomain.com and the other time with different outgoing server which is no way related to my domain but still works. The trickiest par tis that by sending the same message in first case it landed right to the spam folder, the second case - it went as it should - right to the Inbox folder! So basically - by sending identical content from the same email address using different outgoint mail servers - I got different results!

    As soon as I remove http:// link from message body - everything works fine using mail.mydomain.com outgoing server as well, messages are delivered to inbox folder (except that hotmail is still totally ignoring my sent mails)!

    Did the tests with the horde mail from webmail.mydomain.com, the same story - emails with links inside the message text go right to the spam folder!

    Has anybody ran into the same situation and found a solution for this? I suspect that there could be something that needs to be tuned on DNS level?.. I've really ran out of ideas... so expert's input would be a great help!

    Thanks
     
    alise, Apr 6, 2007 IP