In a previous post, I explained how to install the third party (socialite-ui) on your website, which itself was written to help people with the “Gradually migrating to Laravel” post, but it seems it is not enough, so here is how to fully get socialite working, much of the work is outside your website though, and i won’t be covering that, all you need to do is ask google, for example, how do i enable social logins with google or facebook etc…
The redirect problem
After registering or logging in, your user will be redirected to an absolutely empty “/dashboard“, which is already handled by myrouter.php
Email verification
Before doing anything, let us check that email is working using your SMTP credentials
Create the following route for testing
use Illuminate\Support\Facades\Mail;
Route::get('/test-email', function () {
Mail::raw('This is a test email.', function ($message) {
$message->to('test@example.com')
->subject('Test Email');
});
return 'Email sent!';
});
socialite-ui does not come with email verification (during registration) by default, you will need to enable it, this is simply by following the instructions here
now edit the file (/config/socialite-ui.php) to enable the social logins you want enabled, and alter the other settings as per the page her (https://github.com/Laravel-Uis/socialite-ui)
php artisan config:clear
php artisan cache:clear