Confusing Problem With Email Delivery From My Site to AOL / Others

Discussion in 'Site & Server Administration' started by legacy96, May 24, 2008.

  1. #1
    The confirmation emails sent from my website http://earthlandrealms.com when users sign up isn't being delivered to aol.com address's and some other email providers. The strange thing is if I send the same exact email manually using the web based email program Horde, on the same server, using the same email address, it gets delivered. Both Horde and the page sending the email are PHP. The only thing I can think of is that maybe the code is wrong somehow even though the emails do get delivered to gmail and others. Here's the code:

    $ism=mail($cgi['email'],"EarthlandRealms.com Activation e-mail","Welcome to Earthland Realms! \n Your username is: {$cgi['username']} \n Your activation password is {$pas} \n\nEarthlandRealms.com", "From: noreply@dontspamme.com");
    PHP:
    Any ideas?
     
    legacy96, May 24, 2008 IP
  2. gate2vn

    gate2vn Peon

    Messages:
    809
    Likes Received:
    33
    Best Answers:
    1
    Trophy Points:
    0
    #2
    I believe AOL blocks all emails sending by script likes that. AOL can check the header, and if it could not find out a correct mail server, it will block email without question
     
    gate2vn, May 24, 2008 IP
  3. legacy96

    legacy96 Active Member

    Messages:
    124
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    58
    #3
    By why is the same email sent through Horde (a php script) delivered, but the one sent through the confirmation script not delivered (also php script, same from address)? What is Horde doing that the confirmation script is not?
     
    legacy96, May 25, 2008 IP
  4. cmanns

    cmanns Peon

    Messages:
    62
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #4
    because horde uses smtp
     
    cmanns, May 25, 2008 IP
  5. JRBHosting

    JRBHosting Peon

    Messages:
    121
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #5
    AOL needs some headers that other mail carriers may not in order to process incoming e-mail properly, in my experience. Here's what works for me:

    
    $headers = "";
    	$headers .= "From: $EMAIL_FROM<$EMAIL_FROM>\n";
    	$headers .= "Reply-To: <$EMAIL_FROM>\n";
    	$headers .= "X-Sender: <$EMAIL_FROM>\n";
    	$headers .= "X-Mailer: PHP4\n"; //mailer
    	$headers .= "X-Priority: 3\n"; //1 UrgentMessage, 3 Normal
    	$headers .= "Return-Path: <$EMAIL_FROM>\n";
    	$headers .= "Content-Type: text/html; charset=iso-8859-1\n";
    	mail($EMAIL_TO,$EMAIL_SUBJECT,$EMAIL_TEXT,$headers);
    
    Code (markup):
    Jason
     
    JRBHosting, May 25, 2008 IP
  6. legacy96

    legacy96 Active Member

    Messages:
    124
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    58
    #6
    It works! AOL users can finally signup. Thanks!
     
    legacy96, May 25, 2008 IP
  7. JRBHosting

    JRBHosting Peon

    Messages:
    121
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #7
    Yer welcome :)
     
    JRBHosting, May 25, 2008 IP