|
|
|
<extend name="Public/bases" />
|
|
|
|
<block name="body" >
|
|
|
|
<link href="__CSS__/user.css" rel="stylesheet" >
|
|
|
|
<script src="__JS__/jquery-1.11.3.min.js"></script>
|
|
|
|
<script type="text/javascript" src="__JS__/getRem.js"></script>
|
|
|
|
<link rel="stylesheet" type="text/css" href="__CSS__/reset.css">
|
|
|
|
<link rel="stylesheet" type="text/css" href="__CSS__/password.css">
|
|
|
|
<style>
|
|
|
|
body {
|
|
|
|
background: white;
|
|
|
|
}
|
|
|
|
input,button{
|
|
|
|
padding: 0;
|
|
|
|
}
|
|
|
|
</style>
|
|
|
|
<div class="name">
|
|
|
|
<!-- 子页公共头部 -->
|
|
|
|
<div class="subpage-heard">修改密码
|
|
|
|
<a href="javascript:window.history.go(-1);" class="arrows"></a>
|
|
|
|
</div>
|
|
|
|
<form action="" id="form">
|
|
|
|
<div class="login-box">
|
|
|
|
<div class="login-input">
|
|
|
|
<img src="__IMG__/suo.png" alt="">
|
|
|
|
<input type="text" placeholder="请输入原始密码" name="old_pwd" id="old_pwd" value="">
|
|
|
|
</div>
|
|
|
|
<div class="login-input">
|
|
|
|
<img src="__IMG__/suo.png" alt="">
|
|
|
|
<input type="password" placeholder="请输入新密码" name="new_pwd" id="new_pwd" value="">
|
|
|
|
</div>
|
|
|
|
<div class="login-input">
|
|
|
|
<img src="__IMG__/suo.png" alt="">
|
|
|
|
<input type="password" placeholder="请输入新密码" name="com_pwd" id="com_pwd" value="">
|
|
|
|
</div>
|
|
|
|
<div class="login-btn jssubmit">提交</div>
|
|
|
|
</div>
|
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="popmsg pop-dialog"></div>
|
|
|
|
<script src="__JS__/pop.lwx.min.js"></script>
|
|
|
|
<script>
|
|
|
|
$(function() {
|
|
|
|
$('.jssubmit').click(function() {
|
|
|
|
var pmsg = $('.popmsg').pop();
|
|
|
|
if($.trim($("#old_pwd").val()) == ''){
|
|
|
|
pmsg.msg('原始密码不能为空');
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
|
|
|
if($.trim($("#new_pwd").val()).length < 6 || $.trim($("#new_pwd").val()).length > 12){
|
|
|
|
pmsg.msg('密码长度6-12个字符');
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
|
|
|
if($.trim($("#new_pwd").val()) != $.trim($("#com_pwd").val())){
|
|
|
|
pmsg.msg('两次密码输入不一致');
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
$.ajax({
|
|
|
|
url:"{:U('User/userpassword')}",
|
|
|
|
type:"POST",
|
|
|
|
dataType:"json",
|
|
|
|
data:$("#form").serialize(),
|
|
|
|
success:function(result){
|
|
|
|
pmsg.msg(result.info);
|
|
|
|
if(result.url != ''){
|
|
|
|
setTimeout(function () {
|
|
|
|
window.location.href = result.url;
|
|
|
|
}, 2000);
|
|
|
|
}
|
|
|
|
},
|
|
|
|
error:function(){
|
|
|
|
alert('错误');
|
|
|
|
}
|
|
|
|
})
|
|
|
|
});
|
|
|
|
});
|
|
|
|
</script>
|
|
|
|
</block>
|