Hi,
I've just upgraded our site to 4.1.4 with the new public website. After logging in form the public website I'm redirected back to the public website. Is this correct? Since the App site is running on a different port, should I not be redirected there after login, or must I do it myself (and how)?
(or is there something wrong with my setup?)
5 Answer(s)
-
0
Hi,
This is the common design. You should redirected to where you came from. Public and Admin sites are hosted seperately, but they behave like one application. If you want to change this behaviour, you can set returnUrl manually, or redirect it in login action. Or if you explain your scenerio more detailed, we try to help you.
Thanks...
-
0
Hi,
Thanks for the reply.
The issue I have is that after the user signs in from the public website (although the publi and admin function as one) he is redirected to the public website after a successful sign in. From the public website, the user can then only sign out. There is no way for him to get to the Admin site unless he changes the url in the browser manually to the admin site url:port. Should one not be able to browse from the public site to the admin site after login, even if redirected to the public site, or am I missing something?
-
0
In the login button on the public website you will see in the URL a parameter "returnURL". This tells tells the MVC application where to redirect the user to once the automatic sign in is done in the MVC application. You will see by default this returnURL is set to be the public website URL, meaning the user is logged in and redirected back to the public website. Change the returnURL to be what ever URL in your MVC application that you want the user to end up in.
eg. /account/login?ss=true&returnUrl=http://localhost:4200/App
Thanks, Matt
-
0
Thanks Matt, for the feedback and solution.
:D
-
0
Thanks, @Ribbo
@riaan, it makes sense for the user to see the admin link after login. We will add this functionality. Thanks for suggestion...
You can follow this issue: <a class="postlink" href="https://github.com/aspnetzero/aspnet-zero-core/issues/303">https://github.com/aspnetzero/aspnet-ze ... issues/303</a>