Solved

AOL Rejecting my PHP_generated e-mail

Posted on 2013-10-29
13
508 Views
Last Modified: 2013-11-08
I have a PHP script using the mail() function that I am using on a client's website. The user fills out the form, I parse the data, create a nice-looking paragraphy-stlye e-mail and then I send it.
During my testing, I was able to send to multiple addresses with no problem.
When I launched the app and used my client's aol.com address, I called to verify she got the e-mail.  She did not.
I reverted back to my address and it worked again.
I sent the mail to my address and hers.....I go the mail and she did not.  It's as iff AOL is blocking the mail, but based on what criteria?

I have submitted a help ticket to AOL, but a week later I have heard nothing.

Any ideas?

Here is my mail script:

// send e-mail of data
 $to = "xxx@yyy.com";
 $subject = "General Comment/Question";
$mailText = $name . " has submitted information using the general contact form on your website. You can reach " . $name . " via e-mail at " . $email . ", or by phone at (" . $phoneSplit[0] . ") " . $phoneSplit[1] . "-" . $phoneSplit[2] . ". ";
$mailText .= "<br /><br />" . $name . " lives at:<br />" . $addy . "<br />" . $city . ", " . $state . " " . $zip;
$mailText .= "<br /><br />" . $name . " has submitted the following text in the comments and questions textbox:<br /><br /><blockquote>&quot;" . $comms . "&quot;</blockquote>";
$finalText = stripslashes($mailText);
$mymail = "<html><body bgcolor='#FFFFFF'>" . $finalText . "</body></html>";
$mymail = str_replace("\n.", "\n..", $mymail);
$mymail = wordwrap($mymail, 70, "\r\n");
			
// To send HTML mail, the Content-type header must be set
$headers  = 'MIME-Version: 1.0' . "\r\n";
$headers .= 'Content-type: text/html; charset=iso-8859-1' . "\r\n";

// Additional headers
//$headers .= "To: Client Name <zzz@aol.com>\r\n";
$headers .= 'From: zzz@aol.com' . "\r\n" . 'Reply-To: zzz@aol.com' . "\r\n" . 'X-Mailer: PHP/' . phpversion();
 if (mail( $to, $subject, $mymail, $headers)) {
      $success = "Thank you for submitting your request. A member of our staff will be in touch with you shortly.";
}
else {
     $success = "There was an error sending your e-mail. Please try, again.";
}

Open in new window

0
Comment
Question by:dimmergeek
  • 5
  • 4
  • 3
  • +1
13 Comments
 
LVL 58

Expert Comment

by:Gary
ID: 39609083
This is probably relevant
http://blog.mailermailer.com/industry-news/aol-tightens-their-spam-filters

Have you checked the email for spam recognition
http://www.emailspamtest.com/

I assume it is not in the junk folder?
Have you checked the email log for the responses?
0
 
LVL 109

Expert Comment

by:Ray Paseur
ID: 39609196
Ask your client to explicitly "whitelist" your domain and email address.

Generic-sounding text in HTML emails is a hallmark of spam.  Other hallmarks include anti-spam headers that are added by some hosting companies.  If you want to post a complete copy of one of the emails here, including all of the headers, we can show you any stuff like that.

It's really hard work to get automated email right.  If you really want to do this yourself, you may want to learn about PHPMailer.  If you want an easier solution, consider Constant Contact.
0
 
LVL 7

Author Comment

by:dimmergeek
ID: 39609470
GaryC123,
     Thank you for the links.  The mail is not in their junk/spam folder.  It just does not come though at all.  I just ran the emailspam test, and my mail received a scor of 0.8.  Anything above a 5.0 may be classified as spam.
Have you checked the email log for the responses?
I'm not sure where I would go to vew these logs.  I am using BlueHost as the web host.  Where would I find mail logs from teh PHP mail function?
0
3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

 
LVL 58

Expert Comment

by:Gary
ID: 39609492
Do you have a control panel with Bluehost?  Should be an option there for logs.
Are you using your own domain for the email or is it a Bluehost relay?
Maybe an option would be to use GMail to relay the emails.
0
 
LVL 83

Accepted Solution

by:
Dave Baldwin earned 400 total points
ID: 39609537
If you are trying to send 'From:' an AOL email address, that is probably cause enough for them to bounce it or dump it as spam because they know that AOL email does not come from that IP address.  Many other web hosts will also do that.  You should look into creating and using an email address on the domain of the website that can be verified by the mail server that is receiving your emails.
0
 
LVL 109

Expert Comment

by:Ray Paseur
ID: 39609539
Please use my email address in my public profile here and send me the email.  I'll copy it, headers and all, and post it here so we can see what's in there.

Go to "About Me" and scan for "GMail" here:
http://www.experts-exchange.com/M_3774417.html
0
 
LVL 7

Author Comment

by:dimmergeek
ID: 39611287
@Ray, there should be an e-mail in your inbox shortly.
I have created an e-mail address with the host, and that is being used a sthe "From: and "Reply-To" in the e-mail per DaveBaldwin's recommendation.
0
 
LVL 109

Expert Comment

by:Ray Paseur
ID: 39611471
Nothing at all.  Gmail is good at blocking spam, but sometimes semi-legit spam gets through (example Orvis, which spams me every day) and gets put into the spam folder.  But I've gotten nothing new in the last hour.  Did you send the message?
0
 
LVL 7

Author Comment

by:dimmergeek
ID: 39611662
Yes, message was sent.
0
 
LVL 109

Expert Comment

by:Ray Paseur
ID: 39611839
Do you have a gmail account you can try sending it to?  If so you can probably see the original email message including the headers.
0
 
LVL 58

Expert Comment

by:Gary
ID: 39612109
Is Bluehost blocking the email thinking its spam?
0
 
LVL 109

Expert Comment

by:Ray Paseur
ID: 39612168
@GaryC123: That's a good thought.  I recall excluding Bluehost from consideration for a church web site because they had a limit of 400 emails per day, and the church had 1,800 members.  Could be over the limit?
0
 
LVL 58

Expert Comment

by:Gary
ID: 39612204
Doubt it's the limit else no one at all would be getting the email as he did say he does get the email, but you can throw AOL in with Hotmail and the rest of them as spam targets.
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
3 proven steps to speed up Magento powered sites. The article focus is on optimizing time to first byte (TTFB), full page caching and configuring server for optimal performance.
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

821 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question