I was wondering if somebody could help me...
I have created a user login page for my website in VB.Net and ASP.Net.
At the moment, a user logs in with a username and password that has been hardcoded in to my script.
I now need to take it further by removing the hardcoded username and password and coding it so that when the user provides their credentials, my program goes to the virtual FTP server I am using and compares with the credentials for that user in the Active Directory.
Is this possible? if so, what would I need to look into to be able to accomplish this?
My code so far is as follows:
<script runat= "server"> Protected Sub Button1_Click(ByVal sender As Object, ByVal e As EventArgs) Handles Button1.Click Dim Username As String Dim Password As String Username = "username" Password = "password" If txtUsername.Text = "" Then MsgBox("Please provide a username!") End If If txtPassword.Text = "" Then MsgBox("Please provide a password!") End If If txtUsername.Text = username And txtPassword.Text = password Then Response.Redirect("NextPage.aspx") Else MsgBox("Please provide correct credentials!") End If End Sub </script>
Any help and advice will be greatly appreciated.