You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
62 lines
1.8 KiB
HTML
62 lines
1.8 KiB
HTML
5 years ago
|
<extend name="Public/bases" />
|
||
|
<block name="body" >
|
||
|
<link href="__CSS__/user.css" rel="stylesheet" >
|
||
|
<header class="header">
|
||
|
<div class="">
|
||
|
<a href="{:U('User/userset')}" class="hbtn back"><i class="iconfont icon-drop-left"></i></a>
|
||
|
<h1 class="caption">修改昵称</h1>
|
||
|
<a href="javascript:;" class="hbtn addbtn jssubmit">保存</a>
|
||
|
</div>
|
||
|
</header>
|
||
|
<div class="occupy"></div>
|
||
|
<section class="trunker">
|
||
|
<section class="container">
|
||
|
<form id="form" action="" method="post" onsubmit="return false" class="">
|
||
|
<div class="t-table user-auth-list">
|
||
|
<ul class="table clearfix">
|
||
|
<li class="table-row">
|
||
|
<span class="table-cell">昵称</span>
|
||
|
<span class="table-cell">
|
||
|
<input type="text" class="txt" id="nickname" name="nickname" value="{$user['nickname']}" placeholder="请输入昵称">
|
||
|
</span>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</div>
|
||
|
</form>
|
||
|
</section>
|
||
|
</section>
|
||
|
<div class="popmsg pop-dialog"></div>
|
||
|
<script src="__JS__/pop.lwx.min.js"></script>
|
||
|
<script>
|
||
|
$(function() {
|
||
|
$('.jssubmit').click(function() {
|
||
|
var nickname = $.trim($('#nickname').val());
|
||
|
var pmsg = $('.popmsg').pop();
|
||
|
if(nickname == ""){
|
||
|
pmsg.msg("请输入昵称");
|
||
|
return false;
|
||
|
}
|
||
|
$.ajax({
|
||
|
cache:true,
|
||
|
type:'post',
|
||
|
url:"{:U('User/usernick')}",
|
||
|
data:$('#form').serialize(),
|
||
|
dataType:'json',
|
||
|
success:function(result){
|
||
|
pmsg.msg(result.info);
|
||
|
if(result.url !=''){
|
||
|
setTimeout(function () {
|
||
|
window.location.href = result.url;
|
||
|
}, 2000);
|
||
|
|
||
|
}
|
||
|
},
|
||
|
error:function(){
|
||
|
alert("错误")
|
||
|
}
|
||
|
})
|
||
|
return false;
|
||
|
});
|
||
|
});
|
||
|
</script>
|
||
|
</block>
|