protected void btnLogin_Click(object sender, EventArgs e)
 {
     if (Page.IsValid)
     {
         Security.logIn(txtUsername.Text, txtPassword.Text);
         Boolean isLogggedIn = Security.isLoggedIn();
         if (isLogggedIn)
         {
             checkLogin();
             LinksControl control = new LinksControl();
             control.reloadLinks();
             Response.Redirect(Request.Path);
         }
         else
         {
             lblLoginMessage.Text = "Wrong Username or Password. Please Try Again.";
         }
     }
 }
Esempio n. 2
0
 protected void btnLogin_Click(object sender, EventArgs e)
 {
     if (Page.IsValid)
     {
         Security.logIn(txtUsername.Text, txtPassword.Text);
         Boolean isLogggedIn = Security.isLoggedIn();
         if (isLogggedIn)
         {
             checkLogin();
             LinksControl control = new LinksControl();
             control.reloadLinks();
             Response.Redirect(Request.Path);
         }
         else
         {
             lblLoginMessage.Text = "Wrong Username or Password. Please Try Again.";
         }
     }
 }