laravel Expected response code 250 but got code “530”

后端 未结 9 730
有刺的猬
有刺的猬 2020-12-06 17:19

Im trying to Mail in Laravel 5.1

my mail.php code is

 return [
     \'driver\' => env(\'MAIL_DRIVER\', \'smtp\'),
     \'host\' => env(\'MAIL_HOS         


        
相关标签:
9条回答
  • 2020-12-06 18:04

    MAIL_ENCRYPTION=null change it to MAIL_ENCRYPTION=tls

    Just Change your encryption type to 'tls' and it would work and make sure your google account's 'LESS SECURE APP ACCESS' is turned 'ON' and also after changing your .env file you should restart your laravel server.

    Hope it helps.

    0 讨论(0)
  • 2020-12-06 18:08

    Go to Manage Your Google Account page then at the Security tab go to App passwords and get new random code. use it at .env file and replace it with an email password.

    0 讨论(0)
  • 2020-12-06 18:11

    change your MAIL_ENCRYPTION = null to MAIL_ENCRYPTION = ssl or MAIL_ENCRYPTION = tls. i had this issue before and changing to MAIL_ENCRYPTION = tls worked for me. also make sure that your mail settings in config\mail.php is the same as .env file

    0 讨论(0)
提交回复
热议问题