영카트 5.4.3 버전으로 수정

This commit is contained in:
thisgun
2020-10-28 12:08:43 +09:00
32 changed files with 209 additions and 151 deletions

View File

@ -69,5 +69,7 @@ if ($w == '') {
alert('제대로 된 값이 넘어오지 않았습니다.');
}
run_event('admin_boardgroup_form_update', $gr_id, $w);
goto_url('./boardgroup_form.php?w=u&gr_id='.$gr_id.'&'.$qstr);
?>

View File

@ -10,19 +10,23 @@ auth_check($auth[$sub_menu], 'w');
check_admin_token();
$count = count($_POST['chk']);
$post_chk = isset($_POST['chk']) ? (array) $_POST['chk'] : array();
$post_group_id = isset($_POST['group_id']) ? (array) $_POST['group_id'] : array();
$act_button = isset($_POST['act_button']) ? $_POST['act_button'] : '';
$count = count($post_chk);
if(!$count)
alert($_POST['act_button'].'할 게시판그룹을 1개이상 선택해 주세요.');
alert($act_button.'할 게시판그룹을 1개이상 선택해 주세요.');
for ($i=0; $i<$count; $i++)
{
$k = $_POST['chk'][$i];
$gr_id = preg_replace('/[^a-z0-9_]/i', '', $_POST['group_id'][$k]);
$k = $post_chk[$i];
$gr_id = preg_replace('/[^a-z0-9_]/i', '', $post_group_id[$k]);
$gr_subject = is_array($_POST['gr_subject']) ? strip_tags(clean_xss_attributes($_POST['gr_subject'][$k])) : '';
$gr_admin = is_array($_POST['gr_admin']) ? strip_tags(clean_xss_attributes($_POST['gr_admin'][$k])) : '';
if($_POST['act_button'] == '선택수정') {
if($act_button == '선택수정') {
$sql = " update {$g5['group_table']}
set gr_subject = '{$gr_subject}',
gr_device = '".sql_real_escape_string($_POST['gr_device'][$k])."',
@ -33,7 +37,7 @@ for ($i=0; $i<$count; $i++)
if ($is_admin != 'super')
$sql .= " and gr_admin = '{$gr_admin}' ";
sql_query($sql);
} else if($_POST['act_button'] == '선택삭제') {
} else if($act_button == '선택삭제') {
$row = sql_fetch(" select count(*) as cnt from {$g5['board_table']} where gr_id = '$gr_id' ");
if ($row['cnt'])
alert("이 그룹에 속한 게시판이 존재하여 게시판 그룹을 삭제할 수 없습니다.\\n\\n이 그룹에 속한 게시판을 먼저 삭제하여 주십시오.", './board_list.php?sfl=gr_id&amp;stx='.$gr_id);
@ -46,5 +50,7 @@ for ($i=0; $i<$count; $i++)
}
}
run_event('admin_boardgroup_list_update', $act_button, $chk, $post_group_id, $qstr);
goto_url('./boardgroup_list.php?'.$qstr);
?>

View File

@ -1183,7 +1183,7 @@ include_once('_rewrite_config_form.php');
<tr>
<th scope="row"><label for="cf_kakao_rest_key">카카오 REST API 키</label></th>
<td>
<input type="text" name="cf_kakao_rest_key" value="<?php echo $config['cf_kakao_rest_key'] ?>" id="cf_kakao_rest_key" class="frm_input" size="40"> <a href="https://developers.kakao.com/apps/new" target="_blank" class="btn_frmline">앱 등록하기</a>
<input type="text" name="cf_kakao_rest_key" value="<?php echo $config['cf_kakao_rest_key'] ?>" id="cf_kakao_rest_key" class="frm_input" size="40"> <a href="https://developers.kakao.com/product/kakaoLogin" target="_blank" class="btn_frmline">앱 등록하기</a>
</td>
<th scope="row"><label for="cf_kakao_client_secret">카카오 Client Secret</label></th>
<td>

View File

@ -13,16 +13,16 @@ legend {position:absolute;margin:0;padding:0;font-size:0;line-height:0;text-inde
label, input, button, select, img {vertical-align:middle}
input, button {margin:0;padding:0;font-family:'Malgun Gothic',"맑은 고딕",AppleGothic,Dotum,"돋움", sans-serif;font-size:1em}
button,input[type="submit"] {cursor:pointer}
textarea, select {font-family:'Malgun Gothic',"맑은 고딕",AppleGothic,Dotum,"돋움", sans-serif;;font-size:1em}
textarea, select {font-family:'Malgun Gothic',"맑은 고딕",AppleGothic,Dotum,"돋움", sans-serif;font-size:1em}
select {margin:0}
p {margin:0;padding:0;word-break:break-all}
pre {overflow-x:scroll;font-size:1.1em}
a:link, a:visited {color:#000;text-decoration:none}
* {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
h2{font-size: 1.083em;font-weight: bold;margin:10px 0}
@ -39,12 +39,12 @@ h2{font-size: 1.083em;font-weight: bold;margin:10px 0}
#tnb{float:right;padding:10px}
#tnb ul:after{display:block;visibility:hidden;clear:both;content:""}
#tnb li{float:left;position:relative;margin-left:3px}
#tnb a{color:#fff;;padding:0 10px;display:block;line-height:30px;}
#tnb a{color:#fff;padding:0 10px;display:block;line-height:30px;}
#tnb .tnb_service{border-radius:3px;background:#4e5eb7;color:#fff;padding:0 10px;text-align:left;height:30px;line-height:30px;}
#tnb .tnb_service:hover{background:#5969c3}
#tnb button{width:100px;;border:0;border-radius:3px;background:#4e5eb7;color:#fff;padding:0 30px 0 10px;text-align:left;height:30px;position:relative;text-overflow: ellipsis;overflow: hidden;white-space: nowrap;}
#tnb button span{display:block;text-indent:-999px;overflow:hidden;width:30px;border-radius:3px;height:30px;position:absolute;top:0;right:0;background:url(../img/op_btn.png) 50% 50% no-repeat #5969c3}
#tnb button:hover {background:#5969c3}
#tnb button{width:100px;border:0;border-radius:3px;background:#4e5eb7;color:#fff;padding:0 30px 0 10px;text-align:left;height:30px;position:relative;text-overflow: ellipsis;overflow: hidden;white-space: nowrap;}
#tnb button span{display:block;text-indent:-999px;overflow:hidden;width:30px;border-radius:3px;height:30px;position:absolute;top:0;right:0;background:url(../img/op_btn.png) 50% 50% no-repeat #5969c3}
#tnb button:hover {background:#5969c3}
#tnb .tnb_mb_area{display:none;background:#5e6dc2;width:100px;position:absolute;padding:5px;margin-top:1px;}
#tnb .tnb_mb_area a{padding:0}
#tnb .tnb_mb_area li{float:none;}
@ -75,9 +75,9 @@ h2{font-size: 1.083em;font-weight: bold;margin:10px 0}
#gnb .on .btn_op.menu-900{background:url(../img/menu-4.png) 50% 50% no-repeat #fff}
#gnb .gnb_li button:hover{background-color:#f3f3f3}
#gnb .gnb_oparea{display:none;position:absolute;top:0;left:50px;background:#fff;height:100%;width:170px;padding:20px;border-right:1px solid #dbdbdb;
-webkit-box-shadow: 2px 0 2px rgba(150,150,150,100.1);
-moz-box-shadow: 2px 0 2px rgba(150,150,150,0.1);
box-shadow: 2px 0 2px rgba(150,150,150,0.1);}
-webkit-box-shadow: 2px 0 2px rgba(150,150,150,100.1);
-moz-box-shadow: 2px 0 2px rgba(150,150,150,0.1);
box-shadow: 2px 0 2px rgba(150,150,150,0.1);}
#gnb .on .gnb_oparea{display:block}
#gnb .gnb_oparea h3{margin-bottom:10px;line-height:18px;font-size:1.17em}
#gnb .gnb_oparea li{line-height:28px}
@ -182,10 +182,10 @@ a.btn_submit{background:#ff4081;color:#fff}
.btn_add01 button {margin:0}
.td_mng a.btn,.td_mng a{display:inline-block;height:26px;line-height:26px;border:0;;border-radius:3px;padding:0 8px;margin:1px;font-weight:normal}
.td_mng button,.td_mng button.btn{height:26px;border:0;border-radius:3px;padding:0 8px;margin:1px;border:0;;font-weight:normal}
.btn{height:30px;border:0;;border-radius:5px;padding:0 10px;font-weight:bold;font-size:1.09em;vertical-align:middle}
a.btn{display:inline-block;height:30px;line-height:30px;border:0;;border-radius:5px;padding:0 10px;font-weight:bold;font-size:1.09em;;vertical-align:middle}
.td_mng a.btn, .td_mng a{display:inline-block;height:26px;line-height:26px;border:0;border-radius:3px;padding:0 8px;margin:1px;font-weight:normal}
.td_mng button, .td_mng button.btn{height:26px;border:0;border-radius:3px;padding:0 8px;margin:1px;font-weight:normal}
.btn{height:30px;border:0;border-radius:5px;padding:0 10px;font-weight:bold;font-size:1.09em;vertical-align:middle}
a.btn{display:inline-block;height:30px;line-height:30px;border:0;border-radius:5px;padding:0 10px;font-weight:bold;font-size:1.09em;vertical-align:middle}
.btn_submit{background:#ff4081;color:#fff}
a.btn_submit{background:#ff4081;color:#fff}
.btn_submit:hover{background:#ff1464}
@ -196,7 +196,7 @@ a.btn_submit{background:#ff4081;color:#fff}
.btn_03,a.btn_03{background:#3f51b5;color:#fff;}
.btn_frmline{display:inline-block;background:#9eacc6;color:#fff;height:35px;border:0;border-radius:5px;padding:0 10px}
a.btn_frmline{display:inline-block;background:#9eacc6;color:#fff;height:35px;line-height:33px;border-radius:5px;padding:0 10px;text-decoration:none !important}
a.btn_frmline{display:inline-block;background:#9eacc6;color:#fff;height:35px;line-height:33px;border-radius:5px;padding:0 10px;text-decoration:none !important}
.btn_ov01{display:inline-block;line-height:30px;height:30px;font-size:0.92em;vertical-align:top}
.btn_ov01 .ov_txt{float:left;background:#9eacc6;color:#fff;border-radius:5px 0 0 5px;padding:0 5px}
.btn_ov01 .ov_num{float:left;background:#ededed;color:#666;border-radius:0 5px 5px 0;padding:0 5px}
@ -210,7 +210,7 @@ a.btn_ov02:hover,a.ov_listall:hover{background:#3f51b5}
.sound_only {display:inline-block !important;position:absolute;top:0;left:0;margin:0 !important;padding:0 !important;width:1px !important;height:1px !important;font-size:0;line-height:0;border:0 !important;overflow:hidden !important}
.frm_input{height:35px;line-height:32px;border:1px solid #d5d5d5;}
.frm_input_full{width:100%}
.required{background:url('../img/wrest.gif') top right no-repeat #fff !important}
.required{background:url('../img/wrest.gif') top right no-repeat #fff !important}
select{height:35px;line-height:32px;border:1px solid #d5d5d5;}
textarea{width:100%;border:1px solid #d5d5d5;min-height:80px}
legend {position:absolute;width:0;height:0;font-size:0;line-height:0;text-indent:-9999em;border:0;overflow:hidden}
@ -235,7 +235,7 @@ legend {position:absolute;width:0;height:0;font-size:0;line-height:0;text-indent
.color_st03{background:#b668d0;color:#fff;display:inline-block;padding:0 3px;font-size:0.92em;line-height:18px}
.color_st04{background:#ffa700;color:#fff;display:inline-block;padding:0 3px;font-size:0.92em;line-height:18px}
.color_st05{background:#688fef;color:#fff;display:inline-block;padding:0 3px;font-size:0.92em;line-height:18px}
.color_st06{;color:#ff0000;border:1px solid #ff0000;display:inline-block;padding:0 3px;font-size:0.92em;line-height:18px}
.color_st06{color:#ff0000;border:1px solid #ff0000;display:inline-block;padding:0 3px;font-size:0.92em;line-height:18px}
/* 폼 안내글 */
.frm_info {display:block;padding:0 0 5px;color:#5b747e}
@ -245,7 +245,7 @@ legend {position:absolute;width:0;height:0;font-size:0;line-height:0;text-indent
.anchor:after {display:block;visibility:hidden;clear:both;content:""}
.anchor li{float:left;margin-left:-1px;list-style:none}
.anchor a {display:inline-block;padding:5px 10px;border:1px solid #c8ced1;background:#d6dde1;text-decoration:none}
.anchor .selected{background:#3f51b5}
.anchor .selected{background:#3f51b5}
@ -265,22 +265,22 @@ border-bottom: 5px solid black;}
/* 페이지 내 검색 */
.local_sch{}
.local_sch:after ,.local_sch div:after{display:block;visibility:hidden;clear:both;content:""}
.local_sch .btn_sch{width:30px;height:30px;border:0;padding:0;float:left;background:url(../img/sch_btn.png) no-repeat 50% 50%;border:1px solid #dcdcdc;border-left:0;text-indent:-999px;overflow:hidden}
.local_sch .btn_sch2{width:35px;height:35px;border:0;padding:0;background:url(../img/sch_btn.png) no-repeat 50% 50% #eee;border:1px solid #dcdcdc;text-indent:-999px;overflow:hidden}
.local_sch:after, .local_sch div:after{display:block;visibility:hidden;clear:both;content:""}
.local_sch .btn_sch{width:30px;height:30px;border:1px solid #dcdcdc;border-left:0;padding:0;float:left;background:url(../img/sch_btn.png) no-repeat 50% 50%;text-indent:-999px;overflow:hidden}
.local_sch .btn_sch2{width:35px;height:35px;border:1px solid #dcdcdc;padding:0;background:url(../img/sch_btn.png) no-repeat 50% 50% #eee;text-indent:-999px;overflow:hidden}
.local_sch .sch_input{height:30px;border:1px solid #dcdcdc;border-right:0;;padding:0 5px;float:left;}
.local_sch .sch_input{height:30px;border:1px solid #dcdcdc;border-right:0;padding:0 5px;float:left;}
.local_sch select{height:30px;margin-right:3px;border:1px solid #dcdcdc}
.local_sch01{margin: 10px 0;}
.local_sch02{}
.local_sch01 .frm_input{height:30px;border:1px solid #dcdcdc;padding:0 5px;}
.local_sch01 .btn_submit{width:30px;height:30px;border:0;padding:0;background:url(../img/sch_btn.png) no-repeat 50% 50% #eee;border:1px solid #dcdcdc;text-indent:-999px;overflow:hidden}
.local_sch03{;padding:5px 15px;background:#e9ebf9;margin:10px 0}
.local_sch01 .btn_submit{width:30px;height:30px;padding:0;background:url(../img/sch_btn.png) no-repeat 50% 50% #eee;border:1px solid #dcdcdc;text-indent:-999px;overflow:hidden}
.local_sch03{padding:5px 15px;background:#e9ebf9;margin:10px 0}
.local_sch div{margin:5px 0;}
.local_sch03 strong{display:inline-block;width:70px;}
.local_sch03 label{margin-right:5px;display:inline-block}
.local_sch03 label{margin-right:5px;display:inline-block}
.local_sch03 button{height:30px;padding:0 5px;border:0;background:#9eacc6;color:#fff;}
.local_sch03 .btn_submit{height:30px;padding:0 5px;border:0;;color:#fff;}
.local_sch03 .btn_submit{height:30px;padding:0 5px;border:0;color:#fff;}
.local_sch03 .frm_input{height:30px;border:1px solid #dcdcdc;padding:0 5px;}
/* 페이지 내 실행 */
.local_cmd {min-width:960px}
@ -307,6 +307,7 @@ border-bottom: 5px solid black;}
/* 페이지 내 카운트 */
.local_ov {min-width:960px}
.local_ov01 {position:relative;;margin: 10px 0;}
.local_ov01 .ov_a{display:inline-block;line-height:30px;height:30px;font-size:0.92em;background:#ff4081;color:#fff;vertical-align:top;border-radius:5px;padding:0 7px}
.local_ov01 .ov_a:hover{background:#ff1464}
@ -943,7 +944,7 @@ strong.sodr_nonpay {display:block;padding:5px 0;text-align:right}
-moz-box-shadow: 2px 2px 3px 0px rgba(0,0,0,0.2);
box-shadow: 2px 2px 3px 0px rgba(0,0,0,0.2);}
.sv_wrap .sv:before{content: "";position: absolute;top: -6px;left: 15px;width: 0;height: 0;border-style: solid;border-width: 0 6px 6px 6px;border-color: transparent transparent #333 transparent;}
.sv_wrap .sv a {display:inline-block;margin:0;padding:0 10px;line-height:30px;width:100px;font-weight:normal;color:#bbb }
.sv_wrap .sv a {display:inline-block;margin:0;padding:0 10px;line-height:30px;width:100px;font-weight:normal;color:#bbb }
.sv_wrap .sv a:hover{background:#000;color:#fff}
.sv_member{color:#333}
.sv_on {display:block !important;position:absolute;top:23px;left:0px;width:auto;height:auto}
@ -1043,15 +1044,15 @@ box-shadow: 2px 2px 3px 0px rgba(0,0,0,0.2);}
/* 캡챠 */
#captcha {display:inline-block;position:relative}
#captcha legend {position:absolute;margin:0;padding:0;font-size:0;line-height:0;text-indent:-9999em;overflow:hidden;}
#captcha #captcha_img {;height:40px;border:1px solid #898989;vertical-align:top;padding:0;margin:0}
#captcha #captcha_mp3 {;margin:0;padding:0;width:40px;height:40px;border:0;background:transparent;vertical-align:middle;overflow:hidden;cursor:pointer;background:url('../../img/captcha2.png') no-repeat;text-indent:-999px;border-radius:3px}
#captcha #captcha_reload {margin:0;padding:0;width:40px;height:40px;border:0;background:transparent;vertical-align:middle;overflow:hidden;cursor:pointer;background:url('../../img/captcha2.png') no-repeat 0 -40px;text-indent:-999px;border-radius:3px}
#captcha #captcha_img {height:40px;border:1px solid #898989;vertical-align:top;padding:0;margin:0}
#captcha #captcha_mp3 {margin:0;padding:0;width:40px;height:40px;border:0;background:transparent;vertical-align:middle;overflow:hidden;cursor:pointer;background:url('../../img/captcha2.png') no-repeat;text-indent:-999px;border-radius:3px}
#captcha #captcha_reload {margin:0;padding:0;width:40px;height:40px;border:0;background:transparent;vertical-align:middle;overflow:hidden;cursor:pointer;background:url('../../img/captcha2.png') no-repeat 0 -40px;text-indent:-999px;border-radius:3px}
#captcha #captcha_key {margin:0 0 0 3px;padding:0 5px;width:90px;height:40px;border:1px solid #ccc;background:#fff;font-size:1.333em;font-weight:bold;text-align:center;border-radius:3px;vertical-align:top}
#captcha #captcha_info {display:block;margin:5px 0 0;font-size:0.95em;letter-spacing:-0.1em}
/*테마*/
.theme_p{margin:0 0 10px }
#theme_list{padding:0;margin:0;list-style:none; width: 1000px;position:relative}
#theme_list{padding:0;margin:0;list-style:none; width: 1000px;position:relative}
#theme_list:after{display:block;visibility:hidden;clear:both;content:""}
#theme_list li{margin:10px 10px 10px 0;float:left}
@ -1060,33 +1061,33 @@ box-shadow: 2px 2px 3px 0px rgba(0,0,0,0.2);}
#theme_list li .tmli_if>img{width:300px;height:225px;}
#theme_list li .tmli_if:hover>img{-ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=50)";filter: alpha(opacity=50);-moz-opacity:0.5;-khtml-opacity: 0.5;opacity: 0.5;}
#theme_list li .tmli_tit{position:relative; border-top: 1px solid #d1dee2; background: #e5ecef;}
#theme_list li .tmli_tit p{height:40px;line-height:40px;padding:0 10px 0;font-weight:bold;text-overflow: ellipsis; overflow: hidden; white-space: nowrap;}
#theme_list li .tmli_tit p{height:40px;line-height:40px;padding:0 10px 0;font-weight:bold;text-overflow: ellipsis; overflow: hidden; white-space: nowrap;}
#theme_list li .tmli_tit button.tmli_dt{position:absolute;top:8px;right:10px;padding:5px;background:#111;color:#fff;display:none;border:none}
#theme_list li .tmli_if:hover button.tmli_dt{display:block}
#theme_list li .theme_sl{float:left;border:none;margin-top:5px;padding:0 5px;height:26px;background:#999;color:#fff}
#theme_list li .theme_sl:hover{background:#ff3061}
#theme_list li .theme_deactive{margin-left:4px}
#theme_list li .theme_sl_use{background:#ff3061;line-height:26px}
#theme_list li .theme_pr{float:right;margin-top:5px;padding:0 5px;height:26px;line-height:24px; border: 1px solid #ccc; background: #fafafa; }
#theme_list li .theme_preview{ float: right; margin-top: 5px; padding:0 5px;height:26px; border: 1px solid #ccc; background: #fafafa; margin-right:3px}
#theme_list li .theme_pr{float:right;margin-top:5px;padding:0 5px;height:26px;line-height:24px; border: 1px solid #ccc; background: #fafafa; }
#theme_list li .theme_preview{ float: right; margin-top: 5px; padding:0 5px;height:26px; border: 1px solid #ccc; background: #fafafa; margin-right:3px}
#theme_detail{position:fixed;top:50%;height:540px;width:900px;margin-top:-271px;background:#fff;background:#f3f3f3;border:1px solid #000;
-webkit-box-shadow: 1px 2px 5px rgba(150,150,150,100.5);
-moz-box-shadow: 1px 2px 5px rgba(150,150,150,0.5);
box-shadow: 1px 2px 5px rgba(150,150,150,0.5);z-index:1000}
-webkit-box-shadow: 1px 2px 5px rgba(150,150,150,100.5);
-moz-box-shadow: 1px 2px 5px rgba(150,150,150,0.5);
box-shadow: 1px 2px 5px rgba(150,150,150,0.5);z-index:1000}
#theme_detail:after{display:block;visibility:hidden;clear:both;content:""}
#theme_detail h2{font-size:1.25em;background:#fff;padding:0 15px;line-height:40px;border-bottom:1px solid #d8d8d8;margin:0}
.theme_dt_img{float:left;padding:20px}
.theme_dt_img img{border:1px solid #aaa;}
.theme_dt_if{float:left;width:235px;padding:20px 0}
.theme_dt_if table{width:100%;border-collapse:collapse;;margin:15px 0 0 ;font-size:0.92em}
.theme_dt_if table{width:100%;border-collapse:collapse;margin:15px 0 0 ;font-size:0.92em}
.theme_dt_if table th{padding:5px;background:#fff;border-bottom:1px solid #f3f3f3;vertical-align:top;color:#3f51b5}
.theme_dt_if table td{padding:5px;background:#fff;border-bottom:1px solid #f3f3f3;line-height:1.56em}
.theme_dt_if table td a{text-decoration:underline}
.theme_dt_if p{line-height:1.5em}
.if_p_bg{display:inline-block;width:20px;height:1px ;background:#000;margin:30px 0 10px}
#theme_detail .theme_dt_btn{position:absolute;top:0px;right:0px;background:#fff;}
#theme_detail .theme_dt_btn .close_btn{background:url('../img/close.png') 50% 50% no-repeat;width:40px;height:40px;overflow:hidden;border:0;text-indent:-99999px;border-left:1px solid #d8d8d8}
#theme_detail .theme_dt_btn .close_btn{border:0;border-left:1px solid #d8d8d8;background:url('../img/close.png') 50% 50% no-repeat;width:40px;height:40px;overflow:hidden;text-indent:-99999px}
#theme_detail .theme_dt_btn .close_btn:hover{background-color:#eceffc}
#theme_detail .theme_dt_btn .btn_03{line-height:28px;display:inline-block;vertical-align:top;margin-top:6px;padding:0 6px;border-radius:5px}

View File

@ -68,5 +68,7 @@ for ($i=0; $i<$count; $i++)
sql_query($sql);
}
run_event('admin_menu_list_update');
goto_url('./menu_list.php');
?>

View File

@ -298,40 +298,40 @@ if(XenoPostToForm::check()) {
//------------------------------------------------------------------------------
// 기본환경설정
// 기본적으로 사용하는 필드만 얻은 후 상황에 따라 필드를 추가로 얻음
$config = get_config();
$config = get_config(true);
// 본인인증 또는 쇼핑몰 사용시에만 secure; SameSite=None 로 설정합니다.
if( $config['cf_cert_use'] || (defined('G5_YOUNGCART_VER') && G5_YOUNGCART_VER) ) {
// Chrome 80 버전부터 아래 이슈 대응
// https://developers-kr.googleblog.com/2020/01/developers-get-ready-for-new.html?fbclid=IwAR0wnJFGd6Fg9_WIbQPK3_FxSSpFLqDCr9bjicXdzy--CCLJhJgC9pJe5ss
if(!function_exists('session_start_samesite')) {
function session_start_samesite($options = array())
{
// Chrome 80 버전부터 아래 이슈 대응
// https://developers-kr.googleblog.com/2020/01/developers-get-ready-for-new.html?fbclid=IwAR0wnJFGd6Fg9_WIbQPK3_FxSSpFLqDCr9bjicXdzy--CCLJhJgC9pJe5ss
if(!function_exists('session_start_samesite')) {
function session_start_samesite($options = array())
{
global $g5;
$res = @session_start($options);
$res = @session_start($options);
// IE 브라우저 또는 엣지브라우저 또는 IOS 모바일과 http환경에서는 secure; SameSite=None을 설정하지 않습니다.
if( preg_match('/Edge/i', $_SERVER['HTTP_USER_AGENT']) || preg_match('/(iPhone|iPod|iPad).*AppleWebKit.*Safari/i', $_SERVER['HTTP_USER_AGENT']) || preg_match('~MSIE|Internet Explorer~i', $_SERVER['HTTP_USER_AGENT']) || preg_match('~Trident/7.0(; Touch)?; rv:11.0~',$_SERVER['HTTP_USER_AGENT']) || ! (isset($_SERVER['HTTPS']) && $_SERVER['HTTPS']=='on') ){
return $res;
}
$headers = headers_list();
krsort($headers);
foreach ($headers as $header) {
if (!preg_match('~^Set-Cookie: PHPSESSID=~', $header)) continue;
$header = preg_replace('~; secure(; HttpOnly)?$~', '', $header) . '; secure; SameSite=None';
header($header, false);
$headers = headers_list();
krsort($headers);
foreach ($headers as $header) {
if (!preg_match('~^Set-Cookie: PHPSESSID=~', $header)) continue;
$header = preg_replace('~; secure(; HttpOnly)?$~', '', $header) . '; secure; SameSite=None';
header($header, false);
$g5['session_cookie_samesite'] = 'none';
break;
}
return $res;
}
}
break;
}
return $res;
}
}
session_start_samesite();
session_start_samesite();
} else {
@session_start();
@session_start();
}
//==============================================================================
@ -519,7 +519,7 @@ if ($_SESSION['ss_mb_id']) { // 로그인중이라면
$write = array();
$write_table = "";
if ($bo_table) {
$board = get_board_db($bo_table);
$board = get_board_db($bo_table, true);
if ($board['bo_table']) {
set_cookie("ck_bo_table", $board['bo_table'], 86400 * 1);
$gr_id = $board['gr_id'];
@ -542,7 +542,7 @@ if ($bo_table) {
}
if ($gr_id && !is_array($gr_id)) {
$group = get_group($gr_id);
$group = get_group($gr_id, true);
}
if ($config['cf_editor']) {

View File

@ -5,8 +5,8 @@
********************/
define('G5_VERSION', '그누보드5');
define('G5_GNUBOARD_VER', '5.4.2.9');
define('G5_YOUNGCART_VER', '5.4.2.9');
define('G5_GNUBOARD_VER', '5.4.3');
define('G5_YOUNGCART_VER', '5.4.3');
// 이 상수가 정의되지 않으면 각각의 개별 페이지는 별도로 실행될 수 없음
define('_GNUBOARD_', true);

View File

@ -33,9 +33,9 @@ class FileCache
*
* @param string $id
*/
public function get($id)
public function get($id, $expired_time=0)
{
$data = $this->_get($id);
$data = $this->_get($id, $expired_time);
return is_array($data) ? $data['data'] : FALSE;
}
@ -59,7 +59,7 @@ class FileCache
}
protected function _get($id)
protected function _get($id, $expired_time=0)
{
$cache_file_path = $this->get_cache_file_path($id);
@ -68,20 +68,27 @@ class FileCache
return FALSE;
}
$server_time = defined('G5_SERVER_TIME') ? G5_SERVER_TIME : time();
try{
$file_contents = file_get_contents($cache_file_path);
$file_ex = explode("\n\n", $file_contents);
$data = unserialize(base64_decode($file_ex[1]));
} catch(Exception $e){
$data = array('ttl'=>1, 'time'=>time() - 1000);
$data = array('ttl'=>1, 'time'=> $server_time - 1000);
}
if ($data['ttl'] > 0 && time() > $data['time'] + $data['ttl'])
if ($data['ttl'] > 0 && $server_time > $data['time'] + $data['ttl'])
{
unlink( $cache_file_path );
return FALSE;
}
if ($data['time'] && $expired_time && $data['time'] < ($server_time - $expired_time)){
unlink( $cache_file_path );
return FALSE;
}
return $data;
}

View File

@ -52,10 +52,10 @@ function g5_set_cache($key, $save_data, $ttl = null){
}
}
function g5_get_cache($key){
function g5_get_cache($key, $expired_time=0){
if( $cache = get_cachemanage_instance() ){
return $cache->get($key);
return $cache->get($key, $expired_time);
}
return false;

View File

@ -754,6 +754,7 @@ function get_group($gr_id, $is_cache=false)
static $cache = array();
$gr_id = preg_replace('/[^a-z0-9_]/i', '', $gr_id);
$cache = run_replace('get_group_db_cache', $cache, $gr_id, $is_cache);
$key = md5($gr_id);
if( $is_cache && isset($cache[$key]) ){
@ -1605,15 +1606,19 @@ function sql_query($sql, $error=G5_DISPLAY_SQL_ERROR, $link=null)
}
}
$end_time = $is_debug ? get_microtime() : 0;
if($result && $is_debug) {
// 여기에 실행한 sql문을 화면에 표시하는 로직 넣기
$g5_debug['sql'][] = array(
'sql' => $sql,
'start_time' => $start_time,
'end_time' => get_microtime(),
'end_time' => $end_time,
);
}
run_event('sql_query_after', $result, $sql, $start_time, $end_time);
return $result;
}

View File

@ -70,11 +70,10 @@ function get_board_db($bo_table, $is_cache=false){
static $cache = array();
$bo_table = preg_replace('/[^a-z0-9_]/i', '', $bo_table);
$cache = run_replace('get_board_db_cache', $cache, $bo_table, $is_cache);
$key = md5($bo_table);
$bo_table = preg_replace('/[^a-z0-9_]/i', '', $bo_table);
if( $is_cache && isset($cache[$key]) ){
return $cache[$key];
}

View File

@ -9,6 +9,8 @@ function latest($skin_dir='', $bo_table, $rows=10, $subject_len=40, $cache_time=
global $g5;
if (!$skin_dir) $skin_dir = 'basic';
$time_unit = 3600; // 1시간으로 고정
if(preg_match('#^theme/(.+)$#', $skin_dir, $match)) {
if (G5_IS_MOBILE) {
@ -35,7 +37,7 @@ function latest($skin_dir='', $bo_table, $rows=10, $subject_len=40, $cache_time=
if(G5_USE_CACHE) {
$cache_file_name = "latest-{$bo_table}-{$skin_dir}-{$rows}-{$subject_len}-".g5_cache_secret_key();
$caches = g5_get_cache($cache_file_name);
$caches = g5_get_cache($cache_file_name, $time_unit * $cache_time);
$cache_list = isset($caches['list']) ? $caches['list'] : array();
g5_latest_cache_data($bo_table, $cache_list);
}
@ -90,7 +92,7 @@ function latest($skin_dir='', $bo_table, $rows=10, $subject_len=40, $cache_time=
'bo_subject' => sql_escape_string($bo_subject),
);
g5_set_cache($cache_file_name, $caches, 3600 * $cache_time);
g5_set_cache($cache_file_name, $caches, $time_unit * $cache_time);
}
} else {
$list = $cache_list;

View File

@ -16,13 +16,13 @@ function get_pretty_url($folder, $no='', $query_string='', $action='')
return $url;
}
// use shortten url
if($config['cf_bbs_rewrite']) {
// use shortten url
if($config['cf_bbs_rewrite']) {
$segments[0] = G5_URL;
if( $folder === 'content' && $no ){ // 내용관리
$segments[1] = $folder;
if( $config['cf_bbs_rewrite'] > 1 ){
@ -36,32 +36,32 @@ function get_pretty_url($folder, $no='', $query_string='', $action='')
} else if(in_array($folder, $boards)) { // 게시판
$segments[1] = $folder;
$segments[1] = $folder;
if($no) {
if($no) {
if( $config['cf_bbs_rewrite'] > 1 ){
$get_write = get_write( $g5['write_prefix'].$folder, $no , true);
$segments[2] = $get_write['wr_seo_title'] ? urlencode($get_write['wr_seo_title']).'/' : urlencode($no);
$get_write = get_write( $g5['write_prefix'].$folder, $no , true);
$segments[2] = $get_write['wr_seo_title'] ? urlencode($get_write['wr_seo_title']).'/' : urlencode($no);
} else {
$segments[2] = urlencode($no);
}
} else if($action) {
} else if($action) {
$segments[2] = urlencode($action);
}
} else {
} else {
$segments[1] = $folder;
if($no) {
$no_array = explode("=", $no);
$no_value = end($no_array);
if($no) {
$no_array = explode("=", $no);
$no_value = end($no_array);
$segments[2] = urlencode($no_value);
}
}
}
}
if($query_string) {
// If the first character of the query string is '&', replace it with '?'.
@ -72,33 +72,33 @@ function get_pretty_url($folder, $no='', $query_string='', $action='')
}
}
} else { // don't use shortten url
if(in_array($folder, $boards)) {
$url = G5_BBS_URL. '/board.php?bo_table='. $folder;
if($no) {
$url .= '&amp;wr_id='. $no;
}
if($query_string) {
} else { // don't use shortten url
if(in_array($folder, $boards)) {
$url = G5_BBS_URL. '/board.php?bo_table='. $folder;
if($no) {
$url .= '&amp;wr_id='. $no;
}
if($query_string) {
if(substr($query_string, 0, 1) !== '&') {
$url .= '&amp;';
}
$url .= $query_string;
}
} else {
$url = G5_BBS_URL. '/'.$folder.'.php';
$url .= $query_string;
}
} else {
$url = G5_BBS_URL. '/'.$folder.'.php';
if($no) {
$url .= ($folder === 'content') ? '?co_id='. $no : '?'. $no;
}
$url .= ($folder === 'content') ? '?co_id='. $no : '?'. $no;
}
if($query_string) {
$url .= ($no ? '?' : '&amp;'). $query_string;
}
}
}
}
$segments[0] = $url;
}
}
return implode('/', $segments).$add_query;
return implode('/', $segments).$add_query;
}
function short_url_clean($string_url, $add_qry=''){
@ -110,7 +110,7 @@ function short_url_clean($string_url, $add_qry=''){
$string_url = str_replace('&amp;', '&', $string_url);
$url=parse_url($string_url);
$page_name = basename($url['path'],".php");
$array_page_names = run_replace('url_clean_page_names', array('board', 'write', 'content'));
if( stripos(preg_replace('/^https?:/i', '', $string_url), preg_replace('/^https?:/i', '', G5_BBS_URL)) === false || ! in_array($page_name, $array_page_names) ){ //게시판이 아니면 리턴
@ -119,19 +119,19 @@ function short_url_clean($string_url, $add_qry=''){
$return_url = '';
parse_str($url['query'], $vars);
/*
/*
// 예) Array ( [scheme] => http [host] => sir.kr [path] => /bbs/board.php [query] => wr_id=1110870&bo_table=cm_free&cpage=1 [fragment] => c_1110946 )
foreach($vars as $k => $v) { $page_name .= "/".$v; }
*/
foreach($vars as $k => $v) { $page_name .= "/".$v; }
*/
if( $page_name === 'write' ){
$vars['action'] = 'write';
$allow_param_keys = array('bo_table'=>'', 'action'=>'');
} else if( $page_name === 'content' ){
$vars['action'] = 'content';
$allow_param_keys = array('action'=>'', 'co_id'=>'');
} else {
$vars['action'] = 'content';
$allow_param_keys = array('action'=>'', 'co_id'=>'');
} else {
$allow_param_keys = array('bo_table'=>'', 'wr_id'=>'');
}
@ -145,7 +145,7 @@ function short_url_clean($string_url, $add_qry=''){
if( $config['cf_bbs_rewrite'] > 1 && $page_name === 'board' && (isset($s['wr_id']) && $s['wr_id']) && (isset($s['bo_table']) && $s['bo_table']) ){
$get_write = get_write( get_write_table_name($s['bo_table']), $s['wr_id'], true);
if( $get_write['wr_seo_title'] ){
unset($s['wr_id']);
$s['wr_seo_title'] = urlencode($get_write['wr_seo_title']).'/';
@ -175,8 +175,8 @@ function short_url_clean($string_url, $add_qry=''){
if( $add_qry ){
$add_param .= $add_param ? '&amp;'.$add_qry : '?'.$add_qry;
}
foreach($s as $k => $v) { $return_url .= '/'.$v; }
foreach($s as $k => $v) { $return_url .= '/'.$v; }
return $host.$return_url.$add_param.$fragment;
}

View File

@ -159,7 +159,7 @@ jQuery(function($){
</section>
<?php } ?>
<?php if(isset($view['link'][1]) && $view['link'][1]) { ?>
<?php if(isset($view['link']) && array_filter($view['link'])) { ?>
<!-- 관련링크 시작 { -->
<section id="bo_v_link">
<h2>관련링크</h2>

View File

@ -161,7 +161,7 @@ jQuery(function($){
</section>
<?php } ?>
<?php if(isset($view['link'][1]) && $view['link'][1]) { ?>
<?php if(isset($view['link']) && array_filter($view['link'])) { ?>
<!-- 관련링크 시작 { -->
<section id="bo_v_link">
<h2>관련링크</h2>

View File

@ -14,7 +14,7 @@ if( G5_SOCIAL_USE_POPUP ) {
$self_url = G5_SOCIAL_LOGIN_URL.'/popup.php';
}
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css">', 10);
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css?ver='.G5_CSS_VER.'">', 10);
?>
<div class="login-sns sns-wrap-32 sns-wrap-over" id="sns_login">

View File

@ -14,7 +14,7 @@ if( G5_SOCIAL_USE_POPUP ) {
$self_url = G5_SOCIAL_LOGIN_URL.'/popup.php';
}
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css">', 10);
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css?ver='.G5_CSS_VER.'">', 10);
?>
<div class="login-sns sns-wrap-32 sns-wrap-over" id="sns_outlogin">

View File

@ -15,7 +15,7 @@ if( G5_SOCIAL_USE_POPUP ) {
}
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css">', 10);
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css?ver='.G5_CSS_VER.'">', 10);
?>
<div>
<div class="login-sns sns-wrap-32 sns-wrap-over" id="sns_register">

View File

@ -8,7 +8,7 @@ if( ! $config['cf_social_login_use']) { //소셜 로그인을 사용하지
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
add_stylesheet('<link rel="stylesheet" href="'.G5_JS_URL.'/remodal/remodal.css">', 11);
add_stylesheet('<link rel="stylesheet" href="'.G5_JS_URL.'/remodal/remodal-default-theme.css">', 12);
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css">', 13);
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css?ver='.G5_CSS_VER.'">', 13);
add_javascript('<script src="'.G5_JS_URL.'/remodal/remodal.js"></script>', 10);
$email_msg = $is_exists_email ? '등록할 이메일이 중복되었습니다.다른 이메일을 입력해 주세요.' : '';

View File

@ -9,7 +9,7 @@ $socials = social_get_provider_service_name('', 'all');
$session_id = session_id();
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css">', 10);
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css?ver='.G5_CSS_VER.'">', 10);
?>
<li>

View File

@ -118,13 +118,30 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_PLUGIN_URL.'/debugbar/style.cs
$is_print = $rowspan;
foreach($datas as $data){
$print_function = '';
if( $data['function'] && is_array($data['function']) ){
foreach( (array) $data['function'] as $key=>$fn_name ){
$str_delimiter = '';
if($key) $str_delimiter = ' :: ';
if( is_object($fn_name) ){
$fn_name = get_class($fn_name);
}
$print_function .= $str_delimiter.(string) $fn_name;
}
} else {
$print_function = $data['function'];
}
?>
<tr>
<?php if ($is_print){ ?>
<td scope="row" data-label="event_tag" <?php echo $rowspan; ?>><?php echo $tag.' <span class="hook_count">('.$count.')</span>'; ?></td>
<?php } ?>
<td data-label="event_function">
<?php echo $data['function']; ?>
<?php echo $print_function; ?>
</td>
<td data-label="인수의 수"><?php echo $data['arguments']; ?></td>
<td data-label="우선 순위"><?php echo $data['priority']; ?></td>
@ -194,13 +211,30 @@ add_stylesheet('<link rel="stylesheet" href="'.G5_PLUGIN_URL.'/debugbar/style.cs
$is_print = $rowspan;
foreach($datas as $data){
$print_function = '';
if( $data['function'] && is_array($data['function']) ){
foreach( (array) $data['function'] as $key=>$fn_name ){
$str_delimiter = '';
if($key) $str_delimiter = ' :: ';
if( is_object($fn_name) ){
$fn_name = get_class($fn_name);
}
$print_function .= $str_delimiter.(string) $fn_name;
}
} else {
$print_function = $data['function'];
}
?>
<tr>
<?php if ($is_print){ ?>
<td scope="row" data-label="replace_tag" <?php echo $rowspan; ?>><?php echo $tag.' <span class="hook_count">('.$count.')</span>'; ?></td>
<?php } ?>
<td data-label="replace_function">
<?php echo $data['function']; ?>
<?php echo $print_function; ?>
</td>
<td data-label="인수의 수"><?php echo $data['arguments']; ?></td>
<td data-label="우선 순위"><?php echo $data['priority']; ?></td>

View File

@ -176,7 +176,7 @@ add_stylesheet('<link rel="stylesheet" href="'.$board_skin_url.'/style.css">', 0
<!-- } 첨부파일 끝 -->
<?php } ?>
<?php if(isset($view['link'][1]) && $view['link'][1]) { ?>
<?php if(isset($view['link']) && array_filter($view['link'])) { ?>
<!-- 관련링크 시작 { -->
<section id="bo_v_link">
<h2>관련링크</h2>

View File

@ -176,7 +176,7 @@ add_stylesheet('<link rel="stylesheet" href="'.$board_skin_url.'/style.css">', 0
<!-- } 첨부파일 끝 -->
<?php } ?>
<?php if(isset($view['link'][1]) && $view['link'][1]) { ?>
<?php if(isset($view['link']) && array_filter($view['link'])) { ?>
<!-- 관련링크 시작 { -->
<section id="bo_v_link">
<h2>관련링크</h2>

View File

@ -14,7 +14,7 @@ if( G5_SOCIAL_USE_POPUP ) {
$self_url = G5_SOCIAL_LOGIN_URL.'/popup.php';
}
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css">', 10);
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css?ver='.G5_CSS_VER.'">', 10);
?>
<div id="sns_login" class="login-sns sns-wrap-32 sns-wrap-over">

View File

@ -14,7 +14,7 @@ if( G5_SOCIAL_USE_POPUP ) {
$self_url = G5_SOCIAL_LOGIN_URL.'/popup.php';
}
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css">', 10);
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css?ver='.G5_CSS_VER.'">', 10);
?>
<div class="login-sns sns-wrap-32 sns-wrap-over" id="sns_outlogin">

View File

@ -15,7 +15,7 @@ if( G5_SOCIAL_USE_POPUP ) {
}
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css">', 10);
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css?ver='.G5_CSS_VER.'">', 10);
?>
<div>

View File

@ -8,7 +8,7 @@ if( ! $config['cf_social_login_use']) { //소셜 로그인을 사용하지
// add_stylesheet('css 구문', 출력순서); 숫자가 작을 수록 먼저 출력됨
add_stylesheet('<link rel="stylesheet" href="'.G5_JS_URL.'/remodal/remodal.css">', 11);
add_stylesheet('<link rel="stylesheet" href="'.G5_JS_URL.'/remodal/remodal-default-theme.css">', 12);
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css">', 13);
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css?ver='.G5_CSS_VER.'">', 13);
add_javascript('<script src="'.G5_JS_URL.'/remodal/remodal.js"></script>', 10);
$email_msg = $is_exists_email ? '등록할 이메일이 중복되었습니다.다른 이메일을 입력해 주세요.' : '';

View File

@ -9,7 +9,7 @@ $socials = social_get_provider_service_name('', 'all');
$session_id = session_id();
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css">', 10);
add_stylesheet('<link rel="stylesheet" href="'.get_social_skin_url().'/style.css?ver='.G5_CSS_VER.'">', 10);
?>
<li>

View File

@ -159,7 +159,7 @@ jQuery(function($){
</section>
<?php } ?>
<?php if(isset($view['link'][1]) && $view['link'][1]) { ?>
<?php if(isset($view['link']) && array_filter($view['link'])) { ?>
<!-- 관련링크 시작 { -->
<section id="bo_v_link">
<h2>관련링크</h2>

View File

@ -161,7 +161,7 @@ jQuery(function($){
</section>
<?php } ?>
<?php if(isset($view['link'][1]) && $view['link'][1]) { ?>
<?php if(isset($view['link']) && array_filter($view['link'])) { ?>
<!-- 관련링크 시작 { -->
<section id="bo_v_link">
<h2>관련링크</h2>

View File

@ -176,7 +176,7 @@ add_stylesheet('<link rel="stylesheet" href="'.$board_skin_url.'/style.css">', 0
<!-- } 첨부파일 끝 -->
<?php } ?>
<?php if(isset($view['link'][1]) && $view['link'][1]) { ?>
<?php if(isset($view['link']) && array_filter($view['link'])) { ?>
<!-- 관련링크 시작 { -->
<section id="bo_v_link">
<h2>관련링크</h2>

View File

@ -176,7 +176,7 @@ add_stylesheet('<link rel="stylesheet" href="'.$board_skin_url.'/style.css">', 0
<!-- } 첨부파일 끝 -->
<?php } ?>
<?php if(isset($view['link'][1]) && $view['link'][1]) { ?>
<?php if(isset($view['link']) && array_filter($view['link'])) { ?>
<!-- 관련링크 시작 { -->
<section id="bo_v_link">
<h2>관련링크</h2>