private void btnLogin_Click(object sender, EventArgs e) { _splash.Status = @"Logging In."; string lUN = tbUsername.Text.ToLower(); string lPW = tbPassword.Text.ToLower(); lPW = Encryption.GetPassword(lPW, lUN); if (HandleLogin(MySql.GetQuery(QueryIndex.Login2, lUN, lPW)) == 1) { _splash.LoginStatus = true; _splash.Status = @"Success. Welcome " + lUN + "."; Close(); } else { _splash.LoginStatus = false; _splash.Status = @"Log in failed. Please Try again."; tbUsername.Text = ""; tbPassword.Text = ""; tbUsername.Focus(); } }
public void Login(string username, string password) { string query = MySql.GetQuery("UserLogin", username, password); }