PHP Mail Fail on Windows IIS Server

Over the years I’ve transferred a number (too many) PHP websites to Windows servers running PHP (or have had to install PHP apps on a windows server, etc.). One of the biggest problems I always run into when using PHP on a Windows IIS Server is that the PHP Mail Function doesn’t work.

The solution is to change from using the PHP Mail Function to using Authenticated SMTP delivery. In essence, you’ll set up your web app to act like Outlook or Thunderbird to connect to an emailbox directly. This app obviously won’t download any emails; just send them.

You can search for “PHP SMTP email” to get some good solutions to how to handle this with a Pear script.

If you’re using WordPress, though there’s a very simple WordPress Plugin called WP-Mail-SMTP that does all the hard work for you. All you need to do is enter your server information and select your settings.

I just used it, and it took 5 minutes to setup and test.

Keeping your Email Address Away from Spammers

There are many ways that spammers use to acquire email addresses. Some set up fake websites that request emails, and say they’ll give you a 1337″ flat screen TV if you do. Others buy the addresses or hack databases for them, etc.

Some have bots that search the internet for email addresses. The bots search a web pages code for “*@*.com” for example (where * = any amount of characters.) Some bots also search for “mailto:*@*.com” which is the HTML code that you would use to allow a user to click on the link to email you.

Is there a solution? Yes there is! You can replace the certain characters that the bots search for with their html entity code.

For example:

“m” translates into “m”

Phoenix Development put together a little form that will automatically turn your email address into unrecognizable gibberish, that will be translated fine by an Internet Browser.

Email Encoder

-“Spammers are annoying”
-Ashton Sanders

What is Email Spoofing?

This is the first post about email spoofing.

What is Email Spoofing?

Email spoofing is when someone uses your email server to send out spam to other recipients. A lot of the time, the only way you find out you’re getting spoofed is if you have a catch all account, and they send a spam email to a non existent email address… then you get the bounce back. Yes, it is very annoying, especially if they are sending out thousands of spam a day, and you get hundreds of bounce backs.

-Ashton Sanders

Email Whitelisting at AOL

BlackList: If your website (or IP) address is on an email provider’s (like AOL) blacklist, that provider will automatically block any email coming from your IP Address.

WhiteList: You guessed it… the exact opposite of being blacklisted. That provider has recognized you as a legitimate company, and allows your mail to go through to their email clients.

Feedback Loop: When you get feedback from an email provider when your email has been marked as spam by that provider’s customers.

Problem: Email newsletters are not getting opened or, seen.
I had to get a clients IP address whitelisted on the major email providers. Unfortunately, when I got to AOL, too many subscribers had recently marked his newsletters as spam, so my request had been denied. What I did manage to do is get a “Feedback Loop” initiated.

AOL Feedback Loop
A Feedback Loop is very simple: Whenever an AOL member marks your newsletter as spam, sends you an email with a copy of the email that was marked as spam. This will allow you to remove the complainers from your subscriber base.

Note: The email you receive has the headers removed, so you will have to customize your email newsletters so that you can tell who you sent the newsletter to from the body of the newsletter. This is simply done by propagating information to the bottom of every email newsletter before you send it out.

Here is an Example of a footer:

This email was sent to:
*****@****.com at 1:32:56AM.

Then when you receive the complaint, you will be able to see that when you send emails to *****@****.com, they will get marked as spam. And now you can remove them.

Why don’t people use the unsubscribe link?

I can tell you why I don’t use the unsubscribe link on what I think is spam: Some email spammers would prefer to send out spam to random email addresses to see if they will respond. And that unsubscribe link could just send a “I use the email address, spam me!” to the email spammers, and then it’s all over.

How to Get an AOL Feedback Loop Started:

Go to and read up on how the Feedback loop works. Then fill out and submit the Feedback Loop Request Form.

That should get you started on the road to being whitelisted at AOL!

-Good Luck
-Ashton Sanders