>
@@ -215,7 +235,7 @@ $colspan = 15;
|
|
|
- |
+ |
|
|
|
@@ -233,7 +253,8 @@ $colspan = 15;
Yes':'No'; ?> |
value="1"> |
value="1"> |
- value="1"> |
+ > |
+ value="hp"> |
value="1"> |
diff --git a/adm/member_list_update.php b/adm/member_list_update.php
index c468b4f68..aee328184 100644
--- a/adm/member_list_update.php
+++ b/adm/member_list_update.php
@@ -26,13 +26,18 @@ if ($_POST['act_button'] == "선택수정") {
} else if ($member['mb_id'] == $mb['mb_id']) {
$msg .= $mb['mb_id'].' : 로그인 중인 관리자는 수정 할 수 없습니다.\\n';
} else {
+ if($_POST['mb_certify'][$k])
+ $mb_adult = $_POST['mb_adult'][$k];
+ else
+ $mb_adult = 0;
+
$sql = " update {$g4['member_table']}
set mb_level = '{$_POST['mb_level'][$k]}',
mb_intercept_date = '{$_POST['mb_intercept_date'][$k]}',
mb_mailling = '{$_POST['mb_mailling'][$k]}',
mb_open = '{$_POST['mb_open'][$k]}',
mb_certify = '{$_POST['mb_certify'][$k]}',
- mb_adult = '{$_POST['mb_adult'][$k]}'
+ mb_adult = '{$mb_adult}'
where mb_id = '{$_POST['mb_id'][$k]}' ";
sql_query($sql);
}
diff --git a/bbs/write.php b/bbs/write.php
index f4eed3c49..b0a0cfe9c 100644
--- a/bbs/write.php
+++ b/bbs/write.php
@@ -206,6 +206,17 @@ if ($config['cf_cert_use'] && !$is_admin) {
}
}
+// 글자수 제한 설정값
+if ($is_admin || $board['bo_use_dhtml_editor'])
+{
+ $write_min = $write_max = 0;
+}
+else
+{
+ $write_min = (int)$board['bo_write_min'];
+ $write_max = (int)$board['bo_write_max'];
+}
+
$g4['title'] = $board['bo_subject']." ".$title_msg;
$is_notice = false;
diff --git a/install/gnuboard4s.sql b/install/gnuboard4s.sql
index 692b14b1e..90d1b8878 100644
--- a/install/gnuboard4s.sql
+++ b/install/gnuboard4s.sql
@@ -287,6 +287,7 @@ CREATE TABLE IF NOT EXISTS `g4s_config` (
`cf_cert_hp` varchar(255) NOT NULL DEFAULT '',
`cf_cert_kcb_cd` varchar(255) NOT NULL DEFAULT '',
`cf_cert_kcp_cd` varchar(255) NOT NULL DEFAULT '',
+ `cf_cert_limit` int(11) NOT NULL DEFAULT '0',
`cf_googl_shorturl_apikey` varchar(255) NOT NULL DEFAULT '',
`cf_facebook_appid` varchar(255) NOT NULL,
`cf_facebook_secret` varchar(255) NOT NULL,
@@ -317,6 +318,24 @@ CREATE TABLE IF NOT EXISTS `g4s_config` (
-- --------------------------------------------------------
+--
+-- Table structure for table `g4s_cert_history`
+--
+
+CREATE TABLE IF NOT EXISTS `g4s_cert_history` (
+ `cr_id` int(11) NOT NULL auto_increment,
+ `mb_id` varchar(255) NOT NULL DEFAULT '',
+ `cr_company` varchar(255) NOT NULL DEFAULT '',
+ `cr_method` varchar(255) NOT NULL DEFAULT '',
+ `cr_ip` varchar(255) NOT NULL DEFAULT '',
+ `cr_date` date NOT NULL DEFAULT '0000-00-00',
+ `cr_time` time NOT NULL DEFAULT '00:00:00',
+ PRIMARY KEY (`cr_id`),
+ KEY `mb_id` (`mb_id`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8;
+
+-- --------------------------------------------------------
+
--
-- Table structure for table `g4s_group`
--
diff --git a/install/install_db.php b/install/install_db.php
index ff734bd71..afe693e17 100644
--- a/install/install_db.php
+++ b/install/install_db.php
@@ -125,6 +125,7 @@ $sql = " insert into `{$table_prefix}config`
cf_movie_extension = 'asx|asf|wmv|wma|mpg|mpeg|mov|avi|mp3',
cf_formmail_is_member = '1',
cf_page_rows = '15',
+ cf_cert_limit = '2',
cf_stipulation = '해당 홈페이지에 맞는 회원가입약관을 입력합니다.',
cf_privacy = '해당 홈페이지에 맞는 개인정보취급방침을 입력합니다.'
";
@@ -207,6 +208,7 @@ fwrite($f, "\$g4['visit_sum_table'] = G4_TABLE_PREFIX.'visit_sum'; // 방문자
fwrite($f, "\$g4['uniqid_table'] = G4_TABLE_PREFIX.'uniqid'; // 유니크한 값을 만드는 테이블\n");
fwrite($f, "\$g4['syndi_log_table'] = G4_TABLE_PREFIX.'syndi_log'; // 네이버 신디케이션 컨텐츠 삭제 로그 테이블\n");
fwrite($f, "\$g4['autosave_table'] = G4_TABLE_PREFIX.'autosave'; // 게시글 작성시 일정시간마다 글을 임시 저장하는 테이블\n");
+fwrite($f, "\$g4['cert_history_table'] = G4_TABLE_PREFIX.'cert_history'; // 인증내역 테이블\n");
fwrite($f, "?>");
fclose($f);
diff --git a/js/certify.js b/js/certify.js
new file mode 100644
index 000000000..9402449f8
--- /dev/null
+++ b/js/certify.js
@@ -0,0 +1,53 @@
+// 본인확인 인증창 호출
+function certify_win_open(type, url)
+{
+ if(type == 'kcb-ipin')
+ {
+ var popupWindow = window.open( url, "kcbPop", "left=200, top=100, status=0, width=450, height=550" );
+ popupWindow.focus();
+ }
+ else if(type == 'kcb-hp')
+ {
+ var popupWindow = window.open( url, "auth_popup", "left=200, top=100, width=430, height=590, scrollbar=yes" );
+ popupWindow.focus();
+ }
+ else if(type == 'kcp-hp')
+ {
+ if( ( navigator.userAgent.indexOf("Android") > - 1 || navigator.userAgent.indexOf("iPhone") > - 1 ) == false ) // 스마트폰이 아닌경우
+ {
+ var return_gubun;
+ var width = 410;
+ var height = 500;
+
+ var leftpos = screen.width / 2 - ( width / 2 );
+ var toppos = screen.height / 2 - ( height / 2 );
+
+ var winopts = "width=" + width + ", height=" + height + ", toolbar=no,status=no,statusbar=no,menubar=no,scrollbars=no,resizable=no";
+ var position = ",left=" + leftpos + ", top=" + toppos;
+ var AUTH_POP = window.open(url,'auth_popup', winopts + position);
+ }
+ }
+}
+
+// 인증체크
+function cert_confirm()
+{
+ var type;
+ var val = document.fregisterform.cert_type.value
+
+ switch(val) {
+ case "ipin":
+ type = "아이핀";
+ break;
+ case "hp":
+ type = "휴대폰";
+ break;
+ default:
+ return true;
+ }
+
+ if(confirm("이미 "+type+"으로 본인확인을 완료하셨습니다.\n\n이전 인증을 취소하고 다시 인증하시겠습니까?"))
+ return true;
+ else
+ return false;
+}
\ No newline at end of file
diff --git a/lib/common.lib.php b/lib/common.lib.php
index 2df36355f..6e6ad9074 100644
--- a/lib/common.lib.php
+++ b/lib/common.lib.php
@@ -2305,4 +2305,57 @@ function autosave_count($mb_id)
return 0;
}
}
+
+// 본인확인내역 기록
+function insert_cert_history($mb_id, $company, $method)
+{
+ global $g4;
+
+ $sql = " insert into {$g4['cert_history_table']}
+ set mb_id = '$mb_id',
+ cr_company = '$company',
+ cr_method = '$method',
+ cr_ip = '{$_SERVER['REMOTE_ADDR']}',
+ cr_date = '".G4_TIME_YMD."',
+ cr_time = '".G4_TIME_HIS."' ";
+ sql_query($sql);
+}
+
+// 인증시도회수 체크
+function certify_count_check($mb_id, $type)
+{
+ global $g4, $config;
+
+ if($config['cf_cert_use'] != 2)
+ return;
+
+ if($config['cf_cert_limit'] == 0)
+ return;
+
+ $sql = " select count(*) as cnt from {$g4['cert_history_table']} ";
+
+ if($mb_id) {
+ $sql .= " where mb_id = '$mb_id' ";
+ } else {
+ $sql .= " where cr_ip = '{$_SERVER['REMOTE_ADDR']}' ";
+ }
+
+ $sql .= " and cr_method = '".$type."' and cr_date = '".G4_TIME_YMD."' ";
+
+ $row = sql_fetch($sql);
+
+ switch($type) {
+ case 'hp':
+ $cert = '휴대폰';
+ break;
+ case 'ipin':
+ $cert = '아이핀';
+ break;
+ default:
+ break;
+ }
+
+ if((int)$row['cnt'] >= (int)$config['cf_cert_limit'])
+ alert_close('오늘 '.$cert.' 본인확인을 '.$row['cnt'].'회 이용하셔서 더 이상 이용할 수 없습니다.');
+}
?>
\ No newline at end of file
diff --git a/mobile/skin/board/basic/write.skin.php b/mobile/skin/board/basic/write.skin.php
index 429e91276..39c1c1264 100644
--- a/mobile/skin/board/basic/write.skin.php
+++ b/mobile/skin/board/basic/write.skin.php
@@ -107,9 +107,15 @@ echo $option_hidden;
|