Monday, 8 October 2018

How to store IP address of user after login?

How to store IP address of user after login?

https://packalyst.com/packages/package/yadahan/laravel-authentication-log

Follow below url to store IP address of s a user.

composer require yadahan/laravel-authentication-log

php artisan vendor:publish --provider="Yadahan\AuthenticationLog\
AuthenticationLogServiceProvider"

php artisan migrate

App\user.php
Add below lines

use Illuminate\Notifications\Notifiable;
use Yadahan\AuthenticationLog\AuthenticationLogable;
use Illuminate\Foundation\Auth\User as Authenticatable;

class User extends Authenticatable
{
    use Notifiable, AuthenticationLogable;
}

 


No comments:

Post a Comment

Machine Learning - Potato Leaf Disease Prediction

Step 1: import numpy as np import pandas as pd import splitfolders import matplotlib.pyplot as plt import tensorflow as tf from tensorflow i...