Download the PHP package viktor-miller/laravel-confirmation without Composer
On this page you can find all versions of the php package viktor-miller/laravel-confirmation. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download viktor-miller/laravel-confirmation
More information about viktor-miller/laravel-confirmation
Files in viktor-miller/laravel-confirmation
Package laravel-confirmation
Short Description laravel email confirmation package
License MIT
Informations about the package laravel-confirmation
Laravel Email Confirmation
This package is intended to confirm the email address of the user. Tested and used with Laravel 5.4 and 5.5
Features
- Migration to add "confirmed" column to users table
- Migration to create "email_confirmations" table
- Scaffold for view, controller, routes and notification
- Publish translations and configs
- The validation rule for unconfirmed users. The validation rule supports an additional property for setting a pause in hours. For example: after registration, the user is allowed to log in for (n) hours without confirming the email address.
- HTML form for resending a notification with instructions for confirming an email address
- HTML form for confirmation of email address in manual mode (Enter e-mail and token).
- Support for confirmation of the email address in the automatic mode (click on the link that was received by e-mail)
Installation
-
Add package to your composer.json file:
composer require viktor-miller/laravel-confirmation
-
For Laravel 5.4 add service provider and aliase to config/app.php
-
Add a Confirmable trait and implement Confirmable interface on your User model
-
Add validation rule in LoginController and ForgotPasswordController to restrict users with an unconfirmed email address.
For Laravel >= 5.4:
LoginController
and ForgotPasswordController
For Laravel 5.5:
LoginController
and ForgotPasswordController
-
Add event listener to Illuminate\Auth\Events\Registered
-
Run migrations
php artisan migrate
-
Run artisan confirmation command
php artisan confirmation
Publish
If you want to do some changes or add a language you can publish translations
php artisan vendor:publish --tag=confirmation:translations
If you want to do some changes on config you can publish config
php artisan vendor:publish --tag=confirmation:config
Console
supported options
php artisan confirmation -h
Validation
If you want to allow users to ignore the verification rule "verified" for a certain number of hours (for example 24h):
for Laravel >= 5.4
for Laravel >= 5.5