<authentication mode="Forms" > <forms name="logon" path="/" loginUrl="~/logon.aspx" protection="All" timeout="75"/> </authentication > <authorization> <deny users="?"/> </authorization>
protected void Button1_Click(object sender, EventArgs e) { if (TextBox1.Text == "varun" && TextBox2.Text == "v") { FormsAuthentication.RedirectFromLoginPage(TextBox1.Text, CheckBox1.Checked); }
FormsAuthentication.SignOut(); Response.Redirect("logon.aspx");