PHP code example of juriandamen / laramultiauth-v2
1. Go to this page and download the library: Download juriandamen/laramultiauth-v2 library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
use RSpeekenbrink\LaraMultiAuth\LaraMultiAuth;
...
/**
* The user has been authenticated.
*
* @param Request $request
* @param mixed $user
* @return mixed
*/
public function authenticated(Request $request, $user)
{
return LaraMultiAuth::handle($request, $user);
}
use RSpeekenbrink\LaraMultiAuth\HasTOTPAuth;
...
class User extends Authenticatable
{
use HasTOTPAuth;