F
Filament11mo ago
dansing

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
krekas
krekas11mo ago
what is a verification page? after user registers he needs to verify with the link that is sent to email
ocram82
ocram8210mo ago
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
krekas
krekas10mo ago
so where's the problem? it should be done the same way as without filament
Yuvraj Timalsina
Yuvraj Timalsina10mo ago
@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.
ocram82
ocram8210mo ago
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.
krekas
krekas10mo ago
If you have some problems make a help post with code and what isn't working
Yuvraj Timalsina
Yuvraj Timalsina10mo ago
@ocram_82 let me know if you get it to work the way you need.
ocram82
ocram8210mo ago
ok i'm still stuck in this...hope can i do it
krekas
krekas10mo ago
Lol. I don't get it what are you struggling whit? Show some code and what is wrong
ocram82
ocram8210mo ago
Actually i have no code to show. I can't redirect the user, after filament registration, to a custom page. That's it.
krekas
krekas10mo ago
how are you trying to redirect?
ocram82
ocram8210mo ago
how? Filament registration is unaccessible can i modify the behavior of the redirect after registration?
krekas
krekas10mo ago
well yeah
ocram82
ocram8210mo ago
Can you tell me how please?
krekas
krekas10mo ago
why don't you just check source?
krekas
krekas10mo ago
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
krekas
krekas10mo ago
you can overwrite response
krekas
krekas10mo ago
here it is done for login so just change for registration
ocram82
ocram8210mo ago
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!
LeandroFerreira
LeandroFerreira10mo ago
If you want to add this behavior, you should add MustVefifyEmail to the User's model https://discordapp.com/channels/883083792112300104/1151619766134521947/1151658775250485298
ocram82
ocram8210mo ago
yeah. this part was clear from the beginning of the post! thanks