1

We are having some major problems with the new gmail updates. Most of our page doesn't send mails anymore since our MX DNS is linked to Gmail. Now most of our functions that use PHP mail() does ONLY send e-mail every second mail. How come? Anyone experiencing the same issue?

Again, I can confirm that it works for every second mail I send, to certain emails. Not all.

Gjert
  • 1,069
  • 1
  • 18
  • 48
  • I'm not familiar with that particular issue, but in general, most devs would recommend SwiftMailer, PHPMailer or another application like that instead of the default `mail()` function. Have you tried that? – Qirel Mar 11 '16 at 17:42
  • I know, but I've heard that this has affected quite a lot of forms created as widgets etc. in Joomla and Wordpress... Weird that Google would update their system to prevent the standard PHP from working... – Gjert Mar 11 '16 at 17:44
  • I'm guessing it's a measure against spam. Google *hates* spam. – Qirel Mar 11 '16 at 17:50
  • Still, disabling one of the most common mail functions in PHP is pretty radical... – Gjert Mar 11 '16 at 17:52
  • As I said, I don't really have any knowledge about this, but Google set very strict standards about mails coming from `mail()`, the headers have to be near perfect as far as I understand. – Qirel Mar 11 '16 at 17:53
  • It's not for receiving, its for sending from gmail... Our DNS i set so that all outgoing emails are sent using `mail()` – Gjert Mar 11 '16 at 18:25

1 Answers1

0

Check if your mailer supports tls and if you are using SMTPSecure. Both are required by google to minimize spam.

I highly recommend you using a mailer class such as PHP Mailer.

A tutorial for gmail using PHP Mailer : https://github.com/PHPMailer/PHPMailer/blob/master/examples/gmail.phps

Alexander
  • 155
  • 13
  • Why is it all of the sudden required? It has worked all the time until about 4-5 days ago, what is the new update? – Gjert Mar 11 '16 at 17:45
  • I have no idea. GMail is doing weekly updates fixing problems and exploits non stop. I dont know exactly but maybe they have some new security system or something. – Alexander Mar 11 '16 at 17:47