dongxu2398 2019-06-30 10:15
浏览 195

Laravel 5.8 - 无法使用邮件通过Mailgun发送电子邮件

I have spent three days trying to troubleshoot this and run out of ideas. I am trying to send an email using Mailgun, through Laravel 5.8, when directed to the log, it works fine, but when directed to Mailgun, there are no error messages, no email is sent, so obviously it is not received on the specified address, and nothing shows up in mailgun.

The code for sending is shown below.

Mail::to($validatedData['email_address'])->send(new ResetPassword ($account));

I have double checked the correct settings in the .ENV (changing this to log, sends it to the log, changing to Mailgun results in no log entry) so I know that is right.

Having purposely put an error in the ResetPassword mailable to make sure it throws and error, it does, so I know its finding that ok. The view being called exists (the text from the view, together with inserted data, appears in the log when directed there).

I am not using Queues.

The settings for mailgun have been double checked, and I have even regenerated the API key to make sure.

Everything looks right, and produces no error message when run, but no email is sent, can anyone suggest what is going wrong?

  • 写回答

1条回答 默认 最新

  • dowe98261 2019-06-30 10:49
    关注

    Answered my own question!

    The Mailgun Api documentation specified api.mailgun.com/v3/YOURDOMAIN

    However, if you just use api.mailgun.com everything works fine!

    评论

报告相同问题?

悬赏问题

  • ¥15 lammps拉伸应力应变曲线分析
  • ¥15 C++ 头文件/宏冲突问题解决
  • ¥15 用comsol模拟大气湍流通过底部加热(温度不同)的腔体
  • ¥50 安卓adb backup备份子用户应用数据失败
  • ¥20 有人能用聚类分析帮我分析一下文本内容嘛
  • ¥15 请问Lammps做复合材料拉伸模拟,应力应变曲线问题
  • ¥30 python代码,帮调试
  • ¥15 #MATLAB仿真#车辆换道路径规划
  • ¥15 java 操作 elasticsearch 8.1 实现 索引的重建
  • ¥15 数据可视化Python