Hi, as the title says I'm having trouble with the default provider model. I am trying to after the user logs in, redirect to the appropiate page based on his/her role, the problem is it not redirecting appropiately after I deployed the Web site. On my localhost
it's working fine.
the code:
Protected Sub LoginUser_LoggedIn(sender As Object, e As System.EventArgs) Handles LoginUser.LoggedIn
If User.Identity.Name = "juan-pablo" Then
If User.IsInRole("Administrator") Then
Response.Redirect("~/Management/Main.aspx")
Else
Roles.AddUserToRole("juan-pablo", "Administrator")
Response.Redirect("~/Management/Main.aspx")
End If
End If
End Sub
web.config:
<roleManager enabled="true">
<providers>
...
Go to the complete details ...