public void SecondPwd_Set() { mu = buser.GetLogin(false); string action = SafeSC.GetRequest("action"); string pwd = (Request.Form["pwd_t"] ?? "").Trim(' '); string oldpwd = (Request.Form["oldpwd_t"] ?? "").Trim(' '); if (action.Equals("update")) { if (mu.PayPassWord != StringHelper.MD5(oldpwd)) { function.WriteErrMsg("原密码错误,请重新输入!"); return; } } if (string.IsNullOrEmpty(pwd)) { function.WriteErrMsg("二级密码不能为空"); } if (StringHelper.MD5(pwd).Equals(mu.PayPassWord)) { function.WriteErrMsg("新密码和原密码不能相同"); return; } mu.PayPassWord = StringHelper.MD5(pwd); buser.UpDateUser(mu); function.WriteSuccessMsg("操作成功", "/User/Info/Index"); }