/** * Handle a POST request to remind a user of their password. * @return Response */ public function postRemind() { switch ($response = Password::remind(Input::only('email'))) { case Password::INVALID_USER: return Redirect::back()->with('error', Lang::get($response)); case Password::REMINDER_SENT: return Redirect::back()->with('status', Lang::get($response)); } }
/** * Handle a POST request to remind a user of their password. * * @return \Illuminate\Http\RedirectResponse */ public function postRemind() { $result = Password::remind(Input::only('email'), function ($message, $user) { $message->subject(\Lang::get('reminders.your_password_reminder')); }); switch ($result) { case Password::INVALID_USER: return Redirect::back()->with('success', true); case Password::REMINDER_SENT: return Redirect::back()->with('success', true); } }
/** * Handle a POST request to remind a user of their password. * * @return \Illuminate\Http\RedirectResponse */ public function postRemind() { $result = Password::remind(Input::only('email'), function ($message, $user) { $message->subject('Your Password Reminder for Laravel Tricks'); }); switch ($result) { case Password::INVALID_USER: return Redirect::back()->with('success', true); case Password::REMINDER_SENT: return Redirect::back()->with('success', true); } }
/** * Post the forgot password form */ public function postForgotPassword() { return Password::remind(array('email' => Input::get('email'))); }