i have problem login control in asp.net. when entered correct password, login.aspx redirect itself. why? want goto nazarat.aspx after successful login.(account/login.aspx?returnurl=%2fadmin%2fnazarat.aspx)
web.config inside parent folder of nazarat.aspx:
<?xml version="1.0" encoding="utf-8"?> <configuration> <system.web> <authorization> <allow roles="admin" /> <deny users="*" /> </authorization> </system.web> </configuration>
and in login.aspx:
<asp:login id="loginuser" runat="server" enableviewstate="false" renderoutertable="false" > <layouttemplate> .... .... .... </layouttemplate> </asp:login>
is user using login member of role: admin ? per settings:
<allow roles="admin" /> <deny users="*" />
any user admin allowed, other users denied access.
may may want use: ? instead of * in:
<allow roles="admin" /> <deny users="?" />
Comments
Post a Comment