0

I have a live project in my GoDaddy server. I am trying to send an email after submitting a form and for that I have configured .env and mail.php file. But mail is not send and more over that no error file shown in log file.

.env

MAIL_DRIVER=smtp
MAIL_HOST=smtp.gmail.com
MAIL_PORT=587
MAIL_USERNAME=info@gmail.com
MAIL_PASSWORD='app_specific_password'
MAIL_ENCRYPTION=tls

controller

Mail::send('mail', $emailDataArray, function($message) use ($emailDataArray)
{
    $message->to('info@gmail.com')->subject('New Online Estimate');
    $message->from('nfo@gmail.com');
}); 

Mail is not send and no error shown in log file. Anybody Help Please ? I am in serious problem

Raff
  • 5
  • 2
  • 12

2 Answers2

1

Did you activate third party apps on gmail? if no then, go this link , turn on 'Change account access for less secure apps' option

It may be fix your problem.

burakarasu
  • 29
  • 2
  • 7
0

There is no problem with the code, problem is in the Webmail. Consult with the server customer center and Now it's solved.

Raff
  • 5
  • 2
  • 12