PHP code example of socialiteproviders / exment

1. Go to this page and download the library: Download socialiteproviders/exment 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/ */

    

socialiteproviders / exment example snippets


'exment' => [    
  'client_id' => env('EXMENT_CLIENT_ID'),  
  'client_secret' => env('EXMENT_CLIENT_SECRET'),  
  'redirect' => env('EXMENT_REDIRECT_URI'),
  'exment_uri' => env('EXMENT_URI'), // NEED THIS ENV. This is endpoint to access Exment.
],

Event::listen(function (\SocialiteProviders\Manager\SocialiteWasCalled $event) {
    $event->extendSocialite('exment', \SocialiteProviders\Exment\Provider::class);
});

protected $listen = [
    \SocialiteProviders\Manager\SocialiteWasCalled::class => [
        // ... other providers
        \SocialiteProviders\Exment\ExmentExtendSocialite::class.'@handle',
    ],
];

return Socialite::driver('exment')->redirect();