首页 > 代码库 > .Net中BS端代码 理解
.Net中BS端代码 理解
按钮 触发功能 <a class="button whiteButton" href="javascript:void()" onclick="AdminInfoPwd_EditPwd()">确定</a></span>
function AdminInfoPwd_EditPwd() {
$(".errorMsg").html("");
var pwd = GetSharpObj("txt_Pwd");
var newpwd = GetSharpObj("txt_NewPwd");
var repwd = GetSharpObj("txt_RePwd");
if (InputIsEmpty("txt_Pwd") ||$.trim(pwd.val()).length<1) {
GetSharpObj("span_Pwd").html("原密码不能为空");
pwd.focus();
return;
}
var data = "http://www.mamicode.com/pwd=" + pwd.val() + "&newpwd=" + newpwd.val() + "&repwd=" + repwd.val();
SharpAjaxJson("/AdminIndex/AdminPwd", data, function (d) {
if (d.success == "true") {
SharpShowTips(d.message);
AdminInfoPwd_ReSet();
}
else {
GetSharpObj("txt_" + d.targetid).focus();
GetSharpObj("span_" + d.targetid).html(d.message);
}
});
}