-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpassRemindReceive.php
More file actions
90 lines (79 loc) · 2.88 KB
/
passRemindReceive.php
File metadata and controls
90 lines (79 loc) · 2.88 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
<?php
require('function.php');
debug('「「「「「「「「「「「「「「「「「「「「「「「「「');
debug('パスワード再発行認証キー入力ページ');
debug('「「「「「「「「「「「「「「「「「「「「「「「「「');
debugLogstart();
if(empty($_SESSION[('auth_key')])){
header('Location:passRemindSend');
}
if(!empty($_POST)){
debug('POST送信があります');
debug('POST情報:'.print_r($_POST, true));
$auth_key = $_POST['auth_key'];
// 認証キー未入力チェック
validRequire('auth_key');
if(empty($err_msg)){
debug('未入力チェックOK');
// 認証キーの文字数チェック
validLength($auth_key, 'auth_key');
// 半角チェック
validHalf($auth_key, 'auth_key');
if(empty($err_msg)){
// 入力された認証キーが正しいかチェック
if($auth_key !== $_SESSION['auth_key']){
$err_msg['auth_key'] = MSG11;
}
// 認証キーの有効期限をオーバーしていないかチェック
if(time() > $_SESSION['auth_key_limit']){
$err_msg['auth_key'] = MSG12;
}
if(empty($err_msg)){
debug('バリデーションチェックOK');
debug('パスワード再発行画面に遷移します');
header('Location:passRemind.php');
}
}
}
}
?>
<?php
$title = "パスワード再発行ページ";
require('head.php');
?>
<body>
<?php
require('header.php');
?>
<p id="js-show-msg" class="slide-msg" style="display: none;">
<?php
echo getSessionFlash('success-msg');
?>
</p>
<div id=main class="site-width" >
<section class="form-container" style="width: 45%;">
<form action="" method="post" class="form">
<p style="margin-top:20px; margin-bottom: 10px;">
ご指定のメールアドレスお送りした【パスワード再発行認証メール】内にある「認証キー」をご入力ください。
</p>
<div class="area-msg">
<?php
if(!empty($err_msg['common'])) echo $err_msg['common'];
?>
</div>
認証キー
<label for="">
<input type="text" name="auth_key" value="<?php if(!empty($_POST['auth_key'])) echo $_POST['auth_key']?>">
</label>
<div class="area-msg">
<?php
if(!empty($err_msg['auth_key'])) echo $err_msg['auth_key'];
?>
</div>
<input type="submit" name="submit" value="送信">
</form>
</section>
</div>
<?php
require('footer.php');
?>