【发布时间】:2019-05-15 20:21:32
【问题描述】:
Laravel 5.7、PHP 7.2、Mysql 5.7
API 适用于 api.example.com
在APP_URL我设置example.com
在验证邮件中,我收到了一封 URL 为 api.example.com 的邮件
- 缓存已清除
- 没有队列
我觉得
// Illuminate\Auth\Notification\VerifyEmail
URL::temporarySignedRoute
忽略APP_URL
奖励:
在忘记密码邮件的 URL 是好的,
当我输入tinker
URL::temporarySignedRoute(
'verification.verify',
\Illuminate\Support\Carbon::now()->addMinutes(60),
['id' => 1234]
)
我看到带有 example.com 的 URL(是的,缓存已清除,甚至项目从头开始重建)
【问题讨论】:
-
你在 config/app.php 中有什么 url 变量?
-
'url' => env('APP_URL', 'example.com') 当然