카카오 로그인 초기 구현
This commit is contained in:
+1
-1
@@ -111,7 +111,7 @@ $(document).ready( function () {
|
||||
alert(obj.reason);
|
||||
}
|
||||
else{
|
||||
alert('정상적으로 가입되었습니다.');
|
||||
alert('회원 등록되었습니다. 첫 로그인 과정에서 인증 코드를 입력하는 것으로 계정이 활성화됩니다.');
|
||||
}
|
||||
|
||||
window.location.href = "../";
|
||||
|
||||
+33
-4
@@ -48,14 +48,43 @@ $(document).ready( function () {
|
||||
'password':hash_pw
|
||||
}
|
||||
}).then(function(obj){
|
||||
if(!obj.result){
|
||||
if(obj.result){
|
||||
window.location.href = "./";
|
||||
return;
|
||||
}
|
||||
if(!obj.reqOTP){
|
||||
alert(obj.reason);
|
||||
return;
|
||||
}
|
||||
else{
|
||||
window.location.href = 'i_entrance/entrance.php';
|
||||
}
|
||||
$('#modalOTP').modal().on('shown.bs.modal', function(){
|
||||
$('#otp_code').focus();
|
||||
});
|
||||
|
||||
|
||||
});
|
||||
return false;
|
||||
});
|
||||
|
||||
$('#otp_form').submit(function(){
|
||||
$.post({
|
||||
url:'oauth_kakao/j_check_OTP.php',
|
||||
dataType:'json',
|
||||
data:{
|
||||
'otp':$('#otp_code').val(),
|
||||
}
|
||||
}).then(function(obj){
|
||||
if(obj.result){
|
||||
window.location.href = "./";
|
||||
return;
|
||||
}
|
||||
|
||||
alert(obj.reason);
|
||||
|
||||
if(obj.reset){
|
||||
$('#modalOTP').modal('hide')
|
||||
return;
|
||||
}
|
||||
});
|
||||
return false;
|
||||
})
|
||||
} );
|
||||
Reference in New Issue
Block a user