Re: Forms based authentication's Login page posts back to itself instead of redirecting to requested page.
From: Cowboy \(Gregory A. Beamer\) (N0SpamMPleezEgbworld@comcast.netN0SpamMPleezE)
Date: 12/27/02
- Next message: Cowboy \(Gregory A. Beamer\): "Re: permissions for event log"
- Previous message: Cowboy \(Gregory A. Beamer\): "Re: Forms authentication does not work......"
- In reply to: Larry Morris: "FYI: Forms based authentication's Login page posts back to itself instead of redirecting to requested page."
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
From: "Cowboy \(Gregory A. Beamer\)" <N0SpamMPleezEgbworld@comcast.netN0SpamMPleezE> Date: Fri, 27 Dec 2002 09:47:15 -0600
It should either error or send the user to Default.aspx. If you have a
Default.aspx that does either a Server.Transfer or a Response.Redirect to
Login.aspx, there is your problem.
When a person hits the actual login page, rather than attempts another page,
ASP.NET has nowhere to go, so it uses the hardcoded Default.aspx value,
which cannot be changed. You can check for the presence of a redirect URL
and, if missing, redirect to your default page (whatever its name is) with
either Server.Transfer or Response.Redirect.
-- Gregory A. Beamer MVP; MCP: +I, SE, SD, DBA Author: ADO.NET and XML: ASP.NET on the Edge **************************************************************************** **** Think outside the box! **************************************************************************** **** "Larry Morris" <lwmorris067@msn.com> wrote in message news:OB4VozZrCHA.720@TK2MSFTNGP12... > It appears that issuing > System.Web.Security.FormsAuthentication.RedirectFromLoginPage statement > doesn't work when the login page is requested directly and that includes > when the login page is named default.aspx; calling any other page works as > expected. > > Typing http://localhost/myweb/login.aspx will retrieve the login page. > Attempting to login causes the page to simply post back to itself without > redirecting. > Typing http://localhost/myweb/stats.aspx will redirect to the login page. > After loging in, the page redirects to stats.aspx as expected. > > >
- Next message: Cowboy \(Gregory A. Beamer\): "Re: permissions for event log"
- Previous message: Cowboy \(Gregory A. Beamer\): "Re: Forms authentication does not work......"
- In reply to: Larry Morris: "FYI: Forms based authentication's Login page posts back to itself instead of redirecting to requested page."
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|