【问题标题】:Laravel Send Reset Password Using SentryLaravel 使用 Sentry 发送重置密码
【发布时间】:2015-12-25 11:34:17
【问题描述】:

我用 Sentinel(Sentry) 安装 laravel,但我不知道如何使用 sentinel/Sentry 的电子邮件模板发送密码重置

这是我的控制器

$data = array(
    'hash' => Hash::make($user->id),
    "code" => $user->getResetPasswordCode()
);
$send = Mail::send('sentinel.emails.reset', $data, function($message) use($data) {
    $message->to($data["email"], $data["email"])->subject('Info');
});

如何获取代码??

【问题讨论】:

    标签: email laravel


    【解决方案1】:

    使用哨兵

    $user = Sentry::findUserByLogin($request->input('email'));
    $user->getResetPasswordCode()
    

    【讨论】:

      猜你喜欢
      • 2015-07-18
      • 2018-06-04
      • 1970-01-01
      • 1970-01-01
      • 2014-04-06
      • 2017-08-02
      • 2017-08-31
      • 2016-03-01
      • 1970-01-01
      相关资源
      最近更新 更多