login authentication Help needed
-
in an ASP.NET Web application, in the login page,wehn the user enters his username and password,i need to compare the entered username and password with the ones present in the database table. im using c# and sql server2000 plz help :)
You can authenticate users in Asp.Net by one of three ways 1-
Windows Authentication
2-Forms Authentication
3-Passport Authentication
In your case useForms Authentication
To tell Asp.Net to use it in configration file set authontication mode to forms<authentication mode="Forms"> <forms name="MyForm" loginUrl="login.aspx" protection="All" timeout="30" /> </authentication>
In the Login Form Button Clich event handler you can Validate aginest Sel Server database like any SQL Query check if you have record who is name and password equal given values but be aware of sql injection attack when you build your query MCAD
-
You can authenticate users in Asp.Net by one of three ways 1-
Windows Authentication
2-Forms Authentication
3-Passport Authentication
In your case useForms Authentication
To tell Asp.Net to use it in configration file set authontication mode to forms<authentication mode="Forms"> <forms name="MyForm" loginUrl="login.aspx" protection="All" timeout="30" /> </authentication>
In the Login Form Button Clich event handler you can Validate aginest Sel Server database like any SQL Query check if you have record who is name and password equal given values but be aware of sql injection attack when you build your query MCAD