1-888-365-2779
+1-888-365-2779
Try Now
More in this section

Forums / Developing with Sitefinity / Create custom login control based on sitefinity users

Create custom login control based on sitefinity users

2 posts, 0 answered
  1. Annie
    Annie avatar
    123 posts
    Registered:
    08 Apr 2009
    28 May 2009
    Link to this post
    Hi,

    I need to create a custom login control that uses the same login credentials as sitefinity...how do I go about doing this?

    Thanks,
    Annie
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    16 Jun 2017
    28 May 2009
    Link to this post
    Hello Annie,

    You can use the same membership provider as this one in the Sitefinity. Another option is using a custom one with your own users that can be implemented in Sitefinity as well since our implementation is based on ASP.NET membership.

    However you can use asp Login control with the following logic in the code behind.

       void Page_Load(object sender, EventArgs e)  
        {  
            this.Login1.Authenticate += new AuthenticateEventHandler(Login1_Authenticate);  
        }  
     
        void Login1_Authenticate(object sender, AuthenticateEventArgs e)  
        {  
            // gets the default provider that has been set in the web.config  
            e.Authenticated = UserManager.Default.ValidateUser(UserName, Password);  
        } 


    All the best,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
2 posts, 0 answered