information.html
2.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport" />
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
<title>学考无忧-补全信息</title>
<link rel="stylesheet" href="__TMPL__/public/assets/css/reset.css" />
<link rel="stylesheet" href="__TMPL__/public/assets/css/log.css" />
<style type="text/css">
/*log_third页面*/
.log_third_btn {
position: fixed;
bottom: 0rem;
}
</style>
</head>
<body>
<div class="log_top_co">
<!-- 顶部 -->
<div class=" order_top log_top_co">
<a href="">
<img src="__TMPL__/public/assets/images/left.png" alt="" />
</a>
<p>补全信息</p>
</div>
</div>
<div class="log_two_input">
<div class="log_two_input_one">
<div class="log_two_input_title">
姓名
</div>
<div class="log_two_input_contant">
<input type="text" id="name" value="{$data.name}" placeholder="请输入姓名" />
</div>
</div>
<div class="log_two_input_one">
<div class="log_two_input_title">
手机号
</div>
<div class="log_two_input_contant">
<input type="text" placeholder="请输入手机号" value="{$data.phone}" maxlength="11" id="phone" />
</div>
</div>
</div>
<!-- 保存 -->
<div class="log_two_bottom_btn log_third_btn">
<a class="save">保存</a>
</div>
<script src="__TMPL__/public/assets/js/jquery.js"></script>
<script src="__TMPL__/public/assets/js/base.js"></script>
<script>
function checkPhone() {
}
$('.save').click(function(){
var name = $('#name').val();
if(name == ''){
alert("姓名不能为空");
return false
}
var phone = document.getElementById('phone').value;
if(!(/^1[34578]\d{9}$/.test(phone))) {
alert("手机号码有误,请重填");
return false;
}
$.ajax({
url:"{:url('information_save')}",
type:"GET",
data:{'name':name,'phone':phone},
success:function(res){
if(res.code == 1){
alert(res.msg);
window.location.href = "{:url('share/index')}";
}else{
alert(res.msg);
}
},
error:function(res){
alert('与服务器断开连接');
}
})
})
</script>
</body>
</html>