SQL to create the password_resets table
CREATE TABLE `password_resets` (
`email` VARCHAR(255) NOT NULL,
`token` VARCHAR(255) NOT NULL,
`created_at` TIMESTAMP NULL DEFAULT NULL,
INDEX (`email`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
Add controller logic /app/Http/Controllers/Home/AuthController.php
Add view pages
resources/views/static_pages/forgot.blade.php
resources/views/static_pages/reset.blade.php
Add routes (/web.php)
Route::get('/forgot-password', 'AuthController@forgotPasswordForm')->name('forgot.form');
Route::post('/forgot-password', 'AuthController@handleForgotPassword')->name('forgot.handle');
Route::get('/reset-password', 'AuthController@resetPasswordForm')->name('reset.form');
Route::post('/reset-password', 'AuthController@resetPassword')->name('reset.handle');
Add entry on login page
<!-- Add entry on login page -->
<div class="mt-2 text-center">
<a href="{{ route('forgot.form') }}">Forgot password?</a>
</div>
1