How to redirect user to verify email page, after registration?
I'm using the built-in registration feature, and I can't find how to redirect user to verification page after they sign up
22 Replies
what is a verification page? after user registers he needs to verify with the link that is sent to email
Here for the same problem. After registration the email was not sent and the user only see a 403 forbidden because after the registration it log in the user.
The correct way should be:
- User registration
- Message or Page that advice that an email was sent for verification mail
- The user can log in after clicking the verification link
so where's the problem? it should be done the same way as without filament
@krekas I suppose @ocram_82 means to say that registration should act as password reset i.e, after user requests for password reset, it displays a page indicating the user should check the mail, but in case after registration, it displays 403|FORBIDDEN rather than the message indicating that the user should verify his/her email.
Exactly. By the way, i found that maybe this is a problem related to Laravel and not in particular to Filament.
I'm following this link: https://laravel.com/docs/10.x/verification
Laravel - The PHP Framework For Web Artisans
Laravel is a PHP web application framework with expressive, elegant syntax. We’ve already laid the foundation — freeing you to create without sweating the small things.
If you have some problems make a help post with code and what isn't working
@ocram_82 let me know if you get it to work the way you need.
ok i'm still stuck in this...hope can i do it
Lol. I don't get it what are you struggling whit? Show some code and what is wrong
Actually i have no code to show. I can't redirect the user, after filament registration, to a custom page. That's it.
how are you trying to redirect?
how?
Filament registration is unaccessible
can i modify the behavior of the redirect after registration?
well yeah
Can you tell me how please?
why don't you just check source?
particular this line https://github.com/filamentphp/filament/blob/3.x/packages/panels/src/Pages/Auth/Register.php#L87
GitHub
filament/packages/panels/src/Pages/Auth/Register.php at 3.x · filam...
A collection of beautiful full-stack components for Laravel. The perfect starting point for your next app. Using Livewire, Alpine.js and Tailwind CSS. - filamentphp/filament
you can overwrite response
here it is done for login so just change for registration
ok i'll try thanks. Actually i've just seen that link but i could not imagine that it could be works for Registration process
ok i'll try. Actually i've just seen that link but i could not imagine that it could be works for Registration process
@krekas hey man! you've saved my day! I'll be always in debit with a beer with you! thanks a LOT!
If you want to add this behavior, you should add MustVefifyEmail to the User's model
https://discordapp.com/channels/883083792112300104/1151619766134521947/1151658775250485298
yeah. this part was clear from the beginning of the post! thanks