g4s 캡차 코드로 변경

This commit is contained in:
chicpro
2013-03-22 13:03:27 +09:00
parent 9cdad3b0ab
commit 323fadf5e8
7 changed files with 30 additions and 68 deletions

View File

@ -1,6 +1,9 @@
<?
include_once('./_common.php');
include_once(G4_LIB_PATH.'/iteminfo.lib.php');
include_once(G4_GCAPTCHA_PATH.'/gcaptcha.lib.php');
$captcha_html = captcha_html();
// 불법접속을 할 수 없도록 세션에 아무값이나 저장하여 hidden 으로 넘겨서 다음 페이지에서 비교함
$token = md5(uniqid(rand(), true));
@ -721,26 +724,8 @@ function explan_resize_image()
}
</script>
<script type="text/javascript" src="<?=$g4[path]?>/js/jquery.kcaptcha.js"></script>
<script type="text/javascript">
$(function() {
$("#kcaptcha_image_use, #kcaptcha_image_qa").bind("click", function() {
$.ajax({
type: 'POST',
url: g4_path+'/'+g4_bbs+'/kcaptcha_session.php',
cache: false,
async: false,
success: function(text) {
$("#kcaptcha_image_use, #kcaptcha_image_qa").attr('src', g4_path+'/'+g4_bbs+'/kcaptcha_image.php?t=' + (new Date).getTime());
}
});
})
.css('cursor', 'pointer')
.attr('title', '글자가 잘 안보이시는 경우 클릭하시면 새로운 글자가 나옵니다.')
.attr('width', '120')
.attr('height', '60')
.trigger('click');
explan_resize_image();
});
</script>