コード例 #1
0
 protected void On_LoggingIn(object sender, System.Web.UI.WebControls.LoginCancelEventArgs e)
 {
     if (!Validate())
     {
         e.Cancel = true;
     }
 }
コード例 #2
0
 void UserCreator_CreatingUser(object sender, System.Web.UI.WebControls.LoginCancelEventArgs e)
 {
     if (IsEditorOrAdmin(UserCreator.UserName))
     {
         cvError.IsValid      = false;
         cvError.ErrorMessage = "Invalid user name.";
         e.Cancel             = true;
     }
 }
コード例 #3
0
 protected void createUserWizard_CreatingUser(object sender, System.Web.UI.WebControls.LoginCancelEventArgs e)
 {
     if (Page.IsValid)
     {
         this.StatusMessage.Text += "reCAPTCHA validated successfully.<br />";
     }
     else
     {
         // this section is not required, CreateUserWizard will not call this method if a validation error occurs.
     }
 }
コード例 #4
0
 protected void OnLoggingIn(object sender, System.Web.UI.WebControls.LoginCancelEventArgs e)
 {
     if (!IsValidEmail(Login1.UserName))
     {
         Login1.InstructionText = "You must enter a valid e-mail address.";
         e.Cancel = true;
     }
     else
     {
         Login1.InstructionText = String.Empty;
     }
 }
コード例 #5
0
ファイル: Login.aspx.cs プロジェクト: mathewsun/rentoolo.ru
        protected void On_LoggingIn(object sender, System.Web.UI.WebControls.LoginCancelEventArgs e)
        {
            if (IsLocalhost)
            {
                e.Cancel = false;
                return;
            }

            if (!Validate())
            {
                e.Cancel = true;
            }
        }
コード例 #6
0
 protected void LoginStatus_LoggingOut(object sender, System.Web.UI.WebControls.LoginCancelEventArgs e)
 {
     Session["cartList"] = new List <Book>();
 }
コード例 #7
0
        protected void LoginStatus1_LoggingOut(object sender, System.Web.UI.WebControls.LoginCancelEventArgs e)
        {
            string redirectUrl = ConfigurationManager.AppSettings["HCMSPortalBaseURL"].ToString();

            base.FormSignOut(redirectUrl);
        }
コード例 #8
0
ファイル: LoginStatus.cs プロジェクト: dpawatts/zeus
        private void LogoutClicked(object Source, CommandEventArgs e)
        {
            LoginCancelEventArgs args = new LoginCancelEventArgs();
            this.OnLoggingOut(args);
            if (!args.Cancel)
            {
                CurrentAuthenticationService.SignOut();
                this.Page.Response.Clear();
                this.Page.Response.StatusCode = 200;
                this.OnLoggedOut(EventArgs.Empty);
                switch (this.LogoutAction)
                {
                    case System.Web.UI.WebControls.LogoutAction.Refresh:
                        if ((this.Page.Form == null) || !string.Equals(this.Page.Form.Method, "get", StringComparison.OrdinalIgnoreCase))
                        {
                            this.Page.Response.Redirect(new Url(Page.Request.RawUrl).PathAndQuery, false);
                            return;
                        }
                        this.Page.Response.Redirect(this.Page.Request.Path, false);
                        return;

                    case System.Web.UI.WebControls.LogoutAction.Redirect:
                        {
                            string logoutPageUrl = this.LogoutPageUrl;
                            if (string.IsNullOrEmpty(logoutPageUrl))
                                logoutPageUrl = CurrentAuthenticationService.LoginUrl;
                            else
                                logoutPageUrl = base.ResolveClientUrl(logoutPageUrl);
                            this.Page.Response.Redirect(logoutPageUrl, false);
                            return;
                        }
                    case System.Web.UI.WebControls.LogoutAction.RedirectToLoginPage:
                        this.Page.Response.Redirect(CurrentAuthenticationService.LoginUrl, false);
                        return;
                }
            }
        }
コード例 #9
0
ファイル: LoginStatus.cs プロジェクト: dpawatts/zeus
 protected virtual void OnLoggingOut(LoginCancelEventArgs e)
 {
     if (LoggingOut != null)
         LoggingOut(this, e);
 }
コード例 #10
0
        //protected override

        protected override void OnCreatingUser(System.Web.UI.WebControls.LoginCancelEventArgs e)
        {
            this.UserNameRequiredErrorMessage = "lal lgsdhsdhsd ala ";
            //base.OnCreatingUser(e);
        }
コード例 #11
0
 protected void CreateUserWizard1_CreatingUser(object sender, System.Web.UI.WebControls.LoginCancelEventArgs e)
 {
 }
コード例 #12
0
 protected void Login_LoggingIn(object sender, System.Web.UI.WebControls.LoginCancelEventArgs e)
 {
     BitacoraHelper.GrabarEvento("LOGIN USUARIO", ControlLogin.UserName);
 }