Re: Forms authentication - Multiple login forms based on directory acc
- From: Dominick Baier [DevelopMentor] <dbaier@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Tue, 24 Jan 2006 15:06:34 +0000 (UTC)
Hi,
this is not possible. You can however detect in your login page from which area the user is getting forced to login - inspect the ReturnUrl query string.
--------------------------------------- Dominick Baier - DevelopMentor http://www.leastprivilege.com
I want to use ASP.NET 2.0 forms authentication for my new website. I have two different distinct types of user roles... "member" and "admin" each should have access to the /member and /admin directories respectively.
I can make all that work, but the main question I have is with forms authentication it seems that you can only have ONE default login form for the entire application. (loginUrl="~/member/Login.aspx") What I would like is to be able to redirect the user to a different login form based on which area they are trying to access. For example if a user goes here /member/default.aspx and is not authenticated, they would be sent to /member/login.aspx. Likewise, if they are not authenticated and try to access /admin/default.aspx, they are sent to the login form at /member/login.aspx.
I assume I need to handle via the AuthenticateRequest or PostAuthenticateRequest application events, but I have no idea where to start...
Any ideas?
- BK
.
- Prev by Date: Re: Activate account after receiving an e-mail
- Next by Date: Re: Getting list of users(mail,sn) from Active Directory using LDAP question
- Previous by thread: Activate account after receiving an e-mail
- Next by thread: AzMan !!!!
- Index(es):
Relevant Pages
|
|