Try our conversational search powered by Generative AI!

Return url after custom login form(OWIN)

Vote:
 

Hi!

I have a problem with the return url after I use a custom loginform. I am using the following code to do the login  

UISignInManager.Service.SignIn(UIUserProvider.Service.Name, data.userName, data.password) 

everything works fine and I get a true value back. I then try to redirect the user to a url but get a redirect to the startpage instead. No matter what I do I end up on the startpage after a successful login. Is there a way to get around this and to be In controll over the redirect after the login. 

Thanks!

/ Henrik 

#189004
Mar 08, 2018 13:19
Vote:
 

Have you looked at this support article: https://support.episerver.com/hc/en-us/articles/115002559451-Custom-login-page-with-Owin-Authentication and the referenced original blog post?

How do you get the redirect url (or you have already tried to redirect with hardcoded value in the redirect)? No mistake there that you are returning the start page always?

Where ever you are redirecting, the user has access to that page?

#189074
Mar 09, 2018 17:30
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.