충돌 수정
This commit is contained in:
@ -271,6 +271,13 @@ if(!isset($member['mb_scrap_cnt'])) {
|
||||
ADD `mb_scrap_cnt` int(11) NOT NULL DEFAULT '0' AFTER `mb_memo_cnt`", true);
|
||||
}
|
||||
|
||||
// 아이코드 토큰키 추가
|
||||
if( ! isset($config['cf_icode_token_key']) ){
|
||||
$sql = "ALTER TABLE `{$g5['config_table']}`
|
||||
ADD COLUMN `cf_icode_token_key` VARCHAR(100) NOT NULL DEFAULT '' AFTER `cf_icode_server_port`; ";
|
||||
sql_query($sql, false);
|
||||
}
|
||||
|
||||
if(!$config['cf_faq_skin']) $config['cf_faq_skin'] = "basic";
|
||||
if(!$config['cf_mobile_faq_skin']) $config['cf_mobile_faq_skin'] = "basic";
|
||||
|
||||
@ -1257,29 +1264,29 @@ include_once('_rewrite_config_form.php');
|
||||
<tr>
|
||||
<th scope="row"><label for="cf_sms_type">SMS 전송유형</label></th>
|
||||
<td>
|
||||
<?php echo help("전송유형을 SMS로 선택하시면 최대 80바이트까지 전송하실 수 있으며<br>LMS로 선택하시면 90바이트 이하는 SMS로, 그 이상은 1500바이트까지 LMS로 전송됩니다.<br>요금은 건당 SMS는 16원, LMS는 48원입니다."); ?>
|
||||
<?php echo help("전송유형을 SMS로 선택하시면 최대 80바이트까지 전송하실 수 있으며<br>LMS로 선택하시면 90바이트 이하는 SMS로, 그 이상은 ".G5_ICODE_LMS_MAX_LENGTH."바이트까지 LMS로 전송됩니다.<br>요금은 건당 SMS는 16원, LMS는 48원입니다."); ?>
|
||||
<select id="cf_sms_type" name="cf_sms_type">
|
||||
<option value="" <?php echo get_selected($config['cf_sms_type'], ''); ?>>SMS</option>
|
||||
<option value="LMS" <?php echo get_selected($config['cf_sms_type'], 'LMS'); ?>>LMS</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row"><label for="cf_icode_id">아이코드 회원아이디</label></th>
|
||||
<tr class="icode_old_version">
|
||||
<th scope="row"><label for="cf_icode_id">아이코드 회원아이디<br>(구버전)</label></th>
|
||||
<td>
|
||||
<?php echo help("아이코드에서 사용하시는 회원아이디를 입력합니다."); ?>
|
||||
<input type="text" name="cf_icode_id" value="<?php echo $config['cf_icode_id']; ?>" id="cf_icode_id" class="frm_input" size="20">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row"><label for="cf_icode_pw">아이코드 비밀번호</label></th>
|
||||
<tr class="icode_old_version">
|
||||
<th scope="row"><label for="cf_icode_pw">아이코드 비밀번호<br>(구버전)</label></th>
|
||||
<td>
|
||||
<?php echo help("아이코드에서 사용하시는 비밀번호를 입력합니다."); ?>
|
||||
<input type="password" name="cf_icode_pw" value="<?php echo $config['cf_icode_pw']; ?>" id="cf_icode_pw" class="frm_input">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">요금제</th>
|
||||
<tr class="icode_old_version <?php if(!(isset($userinfo['payment']) && $userinfo['payment'])){ echo 'cf_tr_hide'; } ?>">
|
||||
<th scope="row">요금제<br>(구버전)</th>
|
||||
<td>
|
||||
<input type="hidden" name="cf_icode_server_ip" value="<?php echo $config['cf_icode_server_ip']; ?>">
|
||||
<?php
|
||||
@ -1296,21 +1303,31 @@ include_once('_rewrite_config_form.php');
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">아이코드 SMS 신청<br>회원가입</th>
|
||||
<td>
|
||||
<a href="http://icodekorea.com/res/join_company_fix_a.php?sellid=sir2" target="_blank" class="btn_frmline">아이코드 회원가입</a>
|
||||
</td>
|
||||
</tr>
|
||||
<?php if ($userinfo['payment'] == 'A') { ?>
|
||||
<tr>
|
||||
<th scope="row">충전 잔액</th>
|
||||
<?php if ($userinfo['payment'] == 'A') { ?>
|
||||
<tr class="icode_old_version">
|
||||
<th scope="row">충전 잔액<br>(구버전)</th>
|
||||
<td>
|
||||
<?php echo number_format($userinfo['coin']); ?> 원.
|
||||
<a href="http://www.icodekorea.com/smsbiz/credit_card_amt.php?icode_id=<?php echo $config['cf_icode_id']; ?>&icode_passwd=<?php echo $config['cf_icode_pw']; ?>" target="_blank" class="btn_frmline">충전하기</a>
|
||||
</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
<tr class="icode_json_version">
|
||||
<th scope="row"><label for="cf_icode_token_key">아이코드 토큰키<br>(JSON버전)</label></th>
|
||||
<td>
|
||||
<?php echo help("아이코드 JSON 버전의 경우 아이코드 토큰키를 입력시 실행됩니다.<br>SMS 전송유형을 LMS로 설정시 90바이트 이내는 SMS, 90 ~ 2000 바이트는 LMS 그 이상은 절삭 되어 LMS로 발송됩니다."); ?>
|
||||
<input type="text" name="cf_icode_token_key" value="<?php echo $config['cf_icode_token_key']; ?>" id="cf_icode_token_key" class="frm_input" size="40">
|
||||
<?php echo help("아이코드 사이트 -> 토큰키관리 메뉴에서 생성한 토큰키를 입력합니다."); ?>
|
||||
<br>
|
||||
서버아이피 : <?php echo $_SERVER['SERVER_ADDR']; ?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">아이코드 SMS 신청<br>회원가입</th>
|
||||
<td>
|
||||
<a href="http://icodekorea.com/res/join_company_fix_a.php?sellid=sir2" target="_blank" class="btn_frmline">아이코드 회원가입</a>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
@ -36,6 +36,8 @@ foreach( $check_keys as $key ){
|
||||
}
|
||||
}
|
||||
|
||||
$_POST['cf_icode_server_port'] = isset($_POST['cf_icode_server_port']) ? preg_replace('/[^0-9]/', '', $_POST['cf_icode_server_port']) : '7295';
|
||||
|
||||
$sql = " update {$g5['config_table']}
|
||||
set cf_title = '{$_POST['cf_title']}',
|
||||
cf_admin = '{$_POST['cf_admin']}',
|
||||
@ -143,6 +145,7 @@ $sql = " update {$g5['config_table']}
|
||||
cf_sms_type = '{$_POST['cf_sms_type']}',
|
||||
cf_icode_id = '{$_POST['cf_icode_id']}',
|
||||
cf_icode_pw = '{$_POST['cf_icode_pw']}',
|
||||
cf_icode_token_key = '{$_POST['cf_icode_token_key']}',
|
||||
cf_icode_server_ip = '{$_POST['cf_icode_server_ip']}',
|
||||
cf_icode_server_port = '{$_POST['cf_icode_server_port']}',
|
||||
cf_googl_shorturl_apikey = '{$_POST['cf_googl_shorturl_apikey']}',
|
||||
|
||||
@ -535,6 +535,10 @@ td.td_grpset {width:160px;border-left:1px solid #e9ecee;text-align:center}
|
||||
.is_rewrite .info-success{color:#155724}
|
||||
.is_rewrite .info-warning{color:#856404}
|
||||
|
||||
.icode_old_version th{background-color:#FFFCED}
|
||||
.icode_json_version th{background-color:#F6F1FF}
|
||||
.cf_tr_hide {display:none}
|
||||
|
||||
/* 관리권한설정 */
|
||||
#add_admin fieldset {margin-top:20px;overflow:auto;padding:2px 6px;line-height:1.4;resize:vertical}
|
||||
|
||||
|
||||
@ -159,11 +159,11 @@ function add_menu_list(name, link, code)
|
||||
list += "<option value=\"0\">사용안함</option>";
|
||||
list += "</select>";
|
||||
list += "</td>";
|
||||
list += "<td class=\"td_mngsmall\">";
|
||||
list += "<td class=\"td_mng\">";
|
||||
<?php if($new == 'new') { ?>
|
||||
list += "<button type=\"button\" class=\"btn_add_submenu btn\">추가</button>";
|
||||
list += "<button type=\"button\" class=\"btn_add_submenu btn_03\">추가</button>\n";
|
||||
<?php } ?>
|
||||
list += "<button type=\"button\" class=\"btn_del_menu btn\">삭제</button>";
|
||||
list += "<button type=\"button\" class=\"btn_del_menu btn_02\">삭제</button>";
|
||||
list += "</td>";
|
||||
list += "</tr>";
|
||||
|
||||
|
||||
@ -9,6 +9,14 @@ $g5['title'] = "SMS 기본설정";
|
||||
if (!$config['cf_icode_server_ip']) $config['cf_icode_server_ip'] = '211.172.232.124';
|
||||
if (!$config['cf_icode_server_port']) $config['cf_icode_server_port'] = '7295';
|
||||
|
||||
// 아이코드 토큰키 추가
|
||||
if( ! isset($config['cf_icode_token_key']) ){
|
||||
$sql = "ALTER TABLE `{$g5['config_table']}`
|
||||
ADD COLUMN `cf_icode_token_key` VARCHAR(100) NOT NULL DEFAULT '' AFTER `cf_icode_server_port`; ";
|
||||
sql_query($sql, false);
|
||||
$config['cf_icode_token_key'] = '';
|
||||
}
|
||||
|
||||
if ($config['cf_sms_use'] && $config['cf_icode_id'] && $config['cf_icode_pw'])
|
||||
{
|
||||
$userinfo = get_icode_userinfo($config['cf_icode_id'], $config['cf_icode_pw']);
|
||||
@ -23,7 +31,7 @@ if (!$sms5['cf_skin'])
|
||||
include_once(G5_ADMIN_PATH.'/admin.head.php');
|
||||
|
||||
?>
|
||||
<?php if (!$config['cf_icode_pw']) { ?>
|
||||
<?php if (!($config['cf_icode_pw'] || $config['cf_icode_token_key'])) { ?>
|
||||
<div class="local_desc01 local_desc">
|
||||
<p>
|
||||
SMS 기능을 사용하시려면 먼저 아이코드에 서비스 신청을 하셔야 합니다.<br>
|
||||
@ -47,22 +55,31 @@ if ($config['cf_sms_use'] == 'icode') { // 아이코드 사용
|
||||
</colgroup>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th scope="row"><label for="cf_icode_id">아이코드 회원아이디<strong class="sound_only"> 필수</strong></label></th>
|
||||
<th scope="row"><label for="cf_sms_type">SMS 전송유형</label></th>
|
||||
<td>
|
||||
<?php echo help("전송유형을 SMS로 선택하시면 최대 80바이트까지 전송하실 수 있으며<br>LMS로 선택하시면 90바이트 이하는 SMS로, 그 이상은 ".G5_ICODE_LMS_MAX_LENGTH."바이트까지 LMS로 전송됩니다.<br>요금은 건당 SMS는 16원, LMS는 48원입니다."); ?>
|
||||
<select id="cf_sms_type" name="cf_sms_type">
|
||||
<option value="" <?php echo get_selected($config['cf_sms_type'], ''); ?>>SMS</option>
|
||||
<option value="LMS" <?php echo get_selected($config['cf_sms_type'], 'LMS'); ?>>LMS</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="icode_old_version">
|
||||
<th scope="row"><label for="cf_icode_id">아이코드 회원아이디<br>(구버전)<strong class="sound_only"> 필수</strong></label></th>
|
||||
<td>
|
||||
<?php echo help("아이코드에서 사용하시는 회원아이디를 입력합니다."); ?>
|
||||
<input type="text" name="cf_icode_id" value="<?php echo $config['cf_icode_id']; ?>" id="cf_icode_id" required class="frm_input required">
|
||||
<input type="text" name="cf_icode_id" value="<?php echo $config['cf_icode_id']; ?>" id="cf_icode_id" class="frm_input">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row"><label for="cf_icode_pw">아이코드 비밀번호<strong class="sound_only"> 필수</strong></label></th>
|
||||
<tr class="icode_old_version">
|
||||
<th scope="row"><label for="cf_icode_pw">아이코드 비밀번호<br>(구버전)<strong class="sound_only"> 필수</strong></label></th>
|
||||
<td>
|
||||
<?php echo help("아이코드에서 사용하시는 비밀번호를 입력합니다."); ?>
|
||||
<input type="password" name="cf_icode_pw" value="<?php echo $config['cf_icode_pw']; ?>" id="cf_icode_pw" required class="frm_input required">
|
||||
<?php if (!$config['cf_icode_pw']) { ?>현재 비밀번호가 입력되어 있지 않습니다.<?php } ?>
|
||||
<input type="password" name="cf_icode_pw" value="<?php echo $config['cf_icode_pw']; ?>" id="cf_icode_pw" class="frm_input">
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">요금제</th>
|
||||
<tr class="icode_old_version <?php if(!(isset($userinfo['payment']) && $userinfo['payment'])){ echo 'cf_tr_hide'; } ?>">
|
||||
<th scope="row">요금제<br>(구버전)</th>
|
||||
<td>
|
||||
<?php
|
||||
if ($userinfo['payment'] == 'A') {
|
||||
@ -72,21 +89,30 @@ if ($config['cf_sms_use'] == 'icode') { // 아이코드 사용
|
||||
echo '정액제';
|
||||
echo '<input type="hidden" name="cf_icode_server_port" value="7296">';
|
||||
} else {
|
||||
echo '가입해주세요.';
|
||||
echo '<input type="hidden" name="cf_icode_server_port" value="7295">';
|
||||
}
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php if ($userinfo['payment'] == 'A') { ?>
|
||||
<tr>
|
||||
<th scope="row">충전 잔액</th>
|
||||
<tr class="icode_old_version">
|
||||
<th scope="row">충전 잔액<br>(구버전)</th>
|
||||
<td>
|
||||
<?php echo number_format($userinfo['coin'])?> 원
|
||||
<a href="http://www.icodekorea.com/smsbiz/credit_card_amt.php?icode_id=<?php echo $config['cf_icode_id']; ?>&icode_passwd=<?php echo $config['cf_icode_pw']; ?>" target="_blank" class="btn_frmline">충전하기</a>
|
||||
</td>
|
||||
</tr>
|
||||
<?php } ?>
|
||||
<tr class="icode_json_version">
|
||||
<th scope="row"><label for="cf_icode_token_key">아이코드 토큰키<br>(JSON버전)</label></th>
|
||||
<td>
|
||||
<?php echo help("아이코드 JSON 버전의 경우 아이코드 토큰키를 입력시 실행됩니다.<br>SMS 전송유형을 LMS로 설정시 90바이트 이내는 SMS, 90 ~ 2000 바이트는 LMS 그 이상은 절삭 되어 LMS로 발송됩니다."); ?>
|
||||
<input type="text" name="cf_icode_token_key" value="<?php echo $config['cf_icode_token_key']; ?>" id="cf_icode_token_key" class="frm_input" size="40">
|
||||
<?php echo help("아이코드 사이트 -> 토큰키관리 메뉴에서 생성한 토큰키를 입력합니다."); ?>
|
||||
<br>
|
||||
서버아이피 : <?php echo $_SERVER['SERVER_ADDR']; ?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row"><label for="cf_phone">회신번호<strong class="sound_only"> 필수</strong></label></th>
|
||||
<td>
|
||||
|
||||
@ -15,6 +15,7 @@ if(!check_vaild_callback($cf_phone))
|
||||
alert('회신번호가 올바르지 않습니다.');
|
||||
|
||||
$userinfo = get_icode_userinfo($cf_icode_id, $cf_icode_pw);
|
||||
$cf_icode_server_port = isset($cf_icode_server_port) ? preg_replace('/[^0-9]/', '', $cf_icode_server_port) : '7295';
|
||||
|
||||
if ($userinfo['code'] == '202')
|
||||
alert('아이코드 아이디와 패스워드가 맞지 않습니다.');
|
||||
@ -33,10 +34,12 @@ sql_query($sql);
|
||||
// 아이코드 설정
|
||||
$sql = " update {$g5['config_table']}
|
||||
set cf_sms_use = '$cf_sms_use',
|
||||
cf_sms_type = '$cf_sms_type',
|
||||
cf_icode_id = '$cf_icode_id',
|
||||
cf_icode_pw = '$cf_icode_pw',
|
||||
cf_icode_server_ip = '$cf_icode_server_ip',
|
||||
cf_icode_server_port = '$cf_icode_server_port' ";
|
||||
cf_icode_server_port = '$cf_icode_server_port',
|
||||
cf_icode_token_key = '$cf_icode_token_key'";
|
||||
sql_query($sql);
|
||||
|
||||
goto_url("./config.php");
|
||||
|
||||
@ -22,6 +22,7 @@
|
||||
.sms5_box {position:relative;padding:10px;border-radius:5px;background:#fbec99}
|
||||
.sms5_box .box_ico {position:absolute;top:20px;left:-7px;width:7px;height:13px;background:url('../img/box_ico.gif') no-repeat}
|
||||
.sms5_box .box_txt {border:0;background:transparent;word-break:break-all;resize:none;overflow:hidden}
|
||||
.sms5_box textarea.box_txt.is_overview{overflow:visible;min-height:130px}
|
||||
.sms5_box .box_square {width:100px;height:90px}
|
||||
|
||||
#write_wrap {z-index:9}
|
||||
|
||||
@ -224,8 +224,8 @@ if($config['cf_sms_type'] == 'LMS') {
|
||||
|
||||
?>
|
||||
<script>
|
||||
act = window.open('sms_ing.php', 'act', 'width=300, height=200');
|
||||
act.close();
|
||||
//act = window.open('sms_ing.php', 'act', 'width=300, height=200');
|
||||
//act.close();
|
||||
location.href = 'history_view.php?wr_no=<?php echo $wr_no?>&wr_renum=<?php echo $new_wr_renum?>';
|
||||
</script>
|
||||
<?php
|
||||
|
||||
@ -60,8 +60,8 @@ function re_send()
|
||||
if (!confirm('전송에 실패한 SMS 를 재전송 하시겠습니까?'))
|
||||
return;
|
||||
|
||||
act = window.open('sms_ing.php', 'act', 'width=300, height=200');
|
||||
act.focus();
|
||||
//act = window.open('sms_ing.php', 'act', 'width=300, height=200');
|
||||
//act.focus();
|
||||
|
||||
location.href = './history_send.php?w=f&page=<?php echo $page?>&st=<?php echo $st?>&sv=<?php echo $sv?>&wr_no=<?php echo $wr_no?>&wr_renum=<?php echo $wr_renum?>';
|
||||
<?php } ?>
|
||||
@ -104,7 +104,7 @@ function all_send()
|
||||
|
||||
<div id="con_sms" class="sms5_box">
|
||||
<span class="box_ico"></span>
|
||||
<textarea class="box_txt" readonly><?php echo $write['wr_message'];?></textarea>
|
||||
<textarea class="box_txt is_overview" readonly><?php echo $write['wr_message'];?></textarea>
|
||||
</div>
|
||||
|
||||
<?php if ($write['wr_re_total'] && !$wr_renum) { ?>
|
||||
|
||||
@ -149,7 +149,7 @@ CREATE TABLE `{$g5['sms5_write_table']}` (
|
||||
`wr_no` int(11) NOT NULL default '1',
|
||||
`wr_renum` int(11) NOT NULL default '0',
|
||||
`wr_reply` varchar(255) NOT NULL default '',
|
||||
`wr_message` varchar(255) NOT NULL default '',
|
||||
`wr_message` text NOT NULL,
|
||||
`wr_booking` datetime NOT NULL default '0000-00-00 00:00:00',
|
||||
`wr_total` int(11) NOT NULL default '0',
|
||||
`wr_re_total` int(11) NOT NULL default '0',
|
||||
|
||||
@ -266,8 +266,8 @@ function sms5_chk_send(f)
|
||||
|
||||
w = document.body.clientWidth/2 - 200;
|
||||
h = document.body.clientHeight/2 - 100;
|
||||
act = window.open('sms_ing.php', 'act', 'width=300, height=200, left=' + w + ', top=' + h);
|
||||
act.focus();
|
||||
//act = window.open('sms_ing.php', 'act', 'width=300, height=200, left=' + w + ', top=' + h);
|
||||
//act.focus();
|
||||
|
||||
f.send_list.value = list;
|
||||
return true;
|
||||
@ -407,6 +407,7 @@ function byte_check(wr_message, sms_bytes)
|
||||
var conts = document.getElementById(wr_message);
|
||||
var bytes = document.getElementById(sms_bytes);
|
||||
var max_bytes = document.getElementById("sms_max_bytes");
|
||||
var lms_max_length = <?php echo G5_ICODE_LMS_MAX_LENGTH;?>
|
||||
|
||||
var i = 0;
|
||||
var cnt = 0;
|
||||
@ -427,14 +428,14 @@ function byte_check(wr_message, sms_bytes)
|
||||
|
||||
<?php if($config['cf_sms_type'] == 'LMS') { ?>
|
||||
if(cnt > 90)
|
||||
max_bytes.innerHTML = 1500;
|
||||
max_bytes.innerHTML = lms_max_length;
|
||||
else
|
||||
max_bytes.innerHTML = 90;
|
||||
|
||||
if (cnt > 1500)
|
||||
if (cnt > lms_max_length)
|
||||
{
|
||||
exceed = cnt - 1500;
|
||||
alert('메시지 내용은 1500바이트를 넘을수 없습니다.\n\n작성하신 메세지 내용은 '+ exceed +'byte가 초과되었습니다.\n\n초과된 부분은 자동으로 삭제됩니다.');
|
||||
exceed = cnt - lms_max_length;
|
||||
alert('메시지 내용은 '+ lms_max_length +'바이트를 넘을수 없습니다.\n\n작성하신 메세지 내용은 '+ exceed +'byte가 초과되었습니다.\n\n초과된 부분은 자동으로 삭제됩니다.');
|
||||
var tcnt = 0;
|
||||
var xcnt = 0;
|
||||
var tmp = conts.value;
|
||||
@ -447,7 +448,7 @@ function byte_check(wr_message, sms_bytes)
|
||||
tcnt += 1;
|
||||
}
|
||||
|
||||
if (tcnt > 1500) {
|
||||
if (tcnt > lms_max_length) {
|
||||
tmp = tmp.substring(0,i);
|
||||
break;
|
||||
} else {
|
||||
|
||||
@ -6,8 +6,24 @@ auth_check($auth[$sub_menu], "w");
|
||||
|
||||
check_admin_token();
|
||||
|
||||
$result = sql_query("describe `{$g5['sms5_write_table']}`");
|
||||
while ($row = sql_fetch_array($result)){
|
||||
if( $row['Field'] === 'wr_message' && $row['Type'] === 'varchar(255)' ){
|
||||
sql_query("ALTER TABLE `{$g5['sms5_write_table']}` MODIFY wr_message TEXT NOT NULL;", false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
$g5['title'] = "문자전송중";
|
||||
|
||||
if ($config['cf_sms_use'] != 'icode') {
|
||||
alert('기본환경설정에서 icode sms 사용이 비활성화 되어 있습니다.');
|
||||
}
|
||||
|
||||
if ( ! (($config['cf_icode_id'] && $config['cf_icode_pw']) || $config['cf_icode_token_key']) ) {
|
||||
alert('아이코드 설정값이 존재하지 않습니다.');
|
||||
}
|
||||
|
||||
$wr_reply = preg_replace('#[^0-9\-]#', '', trim($wr_reply));
|
||||
$wr_message = clean_xss_tags(trim($wr_message));
|
||||
|
||||
@ -94,12 +110,12 @@ while ($row = array_shift($send_list))
|
||||
$hp = get_hp($item[$i][1], 0);
|
||||
$name = $item[$i][0];
|
||||
|
||||
if(!$hp) continue;
|
||||
if(!$hp) continue 2;
|
||||
|
||||
if ($wr_overlap && array_overlap($hps, $hp)) {
|
||||
$overlap++;
|
||||
array_push( $duplicate_data['hp'], $row['bk_hp'] );
|
||||
continue;
|
||||
continue 2;
|
||||
}
|
||||
|
||||
array_push($list, array('bk_hp' => $hp, 'bk_name' => $name));
|
||||
@ -111,12 +127,12 @@ while ($row = array_shift($send_list))
|
||||
$row = sql_fetch("select * from {$g5['sms5_book_table']} where bk_no='$item[$i]'");
|
||||
$row['bk_hp'] = get_hp($row['bk_hp'], 0);
|
||||
|
||||
if(!$row['bk_hp']) continue;
|
||||
if(!$row['bk_hp']) continue 2;
|
||||
|
||||
if ($wr_overlap && array_overlap($hps, $row['bk_hp'])) {
|
||||
$overlap++;
|
||||
array_push( $duplicate_data['hp'], $row['bk_hp'] );
|
||||
continue;
|
||||
continue 2;
|
||||
}
|
||||
array_push($list, $row);
|
||||
array_push($hps, $row['bk_hp']);
|
||||
@ -141,14 +157,11 @@ if ($wr_by && $wr_bm && $wr_bd && $wr_bh && $wr_bi) {
|
||||
$booking = '';
|
||||
}
|
||||
|
||||
if ($config['cf_sms_use'] != 'icode') {
|
||||
alert('기본환경설정에서 icode sms 사용이 비활성화 되어 있습니다.');
|
||||
}
|
||||
|
||||
include_once(G5_ADMIN_PATH.'/admin.head.php');
|
||||
|
||||
$reply = str_replace('-', '', trim($wr_reply));
|
||||
$wr_message = conv_unescape_nl($wr_message);
|
||||
$db_wr_message = conv_unescape_nl($wr_message);
|
||||
$wr_message = conv_unescape_nl(stripslashes($wr_message));
|
||||
|
||||
$SMS = new SMS5;
|
||||
|
||||
@ -186,7 +199,7 @@ if($config['cf_sms_type'] == 'LMS') {
|
||||
|
||||
if($result) {
|
||||
$result = $SMS->Send();
|
||||
|
||||
|
||||
if ($result) //SMS 서버에 접속했습니다.
|
||||
{
|
||||
foreach ($SMS->Result as $result)
|
||||
@ -242,7 +255,7 @@ if($config['cf_sms_type'] == 'LMS') {
|
||||
}
|
||||
}
|
||||
|
||||
sql_query("insert into {$g5['sms5_write_table']} set wr_no='$wr_no', wr_renum=0, wr_reply='$wr_reply', wr_message='$wr_message', wr_success='$wr_success', wr_failure='$wr_failure', wr_memo='$str_serialize', wr_booking='$wr_booking', wr_total='$wr_total', wr_datetime='".G5_TIME_YMDHIS."'");
|
||||
sql_query("insert into {$g5['sms5_write_table']} set wr_no='$wr_no', wr_renum=0, wr_reply='$wr_reply', wr_message='$db_wr_message', wr_success='$wr_success', wr_failure='$wr_failure', wr_memo='$str_serialize', wr_booking='$wr_booking', wr_total='$wr_total', wr_datetime='".G5_TIME_YMDHIS."'");
|
||||
}
|
||||
} else {
|
||||
$SMS->SMS_con($config['cf_icode_server_ip'], $config['cf_icode_id'], $config['cf_icode_pw'], $config['cf_icode_server_port']);
|
||||
@ -260,7 +273,7 @@ if($config['cf_sms_type'] == 'LMS') {
|
||||
else
|
||||
$wr_no = 1;
|
||||
|
||||
sql_query("insert into {$g5['sms5_write_table']} set wr_no='$wr_no', wr_renum=0, wr_reply='$wr_reply', wr_message='$wr_message', wr_booking='$wr_booking', wr_total='$wr_total', wr_datetime='".G5_TIME_YMDHIS."'");
|
||||
sql_query("insert into {$g5['sms5_write_table']} set wr_no='$wr_no', wr_renum=0, wr_reply='$wr_reply', wr_message='$db_wr_message', wr_booking='$wr_booking', wr_total='$wr_total', wr_datetime='".G5_TIME_YMDHIS."'");
|
||||
|
||||
$wr_success = 0;
|
||||
$wr_failure = 0;
|
||||
@ -324,11 +337,16 @@ if($config['cf_sms_type'] == 'LMS') {
|
||||
|
||||
function win_close_alert($msg) {
|
||||
|
||||
$html = "<script>
|
||||
act = window.open('sms_ing.php', 'act', 'width=300, height=200');
|
||||
act.close();
|
||||
alert('$msg');
|
||||
history.back();</script>";
|
||||
$html = "<script>".PHP_EOL;
|
||||
//$html .= "act = window.open('sms_ing.php', 'act', 'width=300, height=200');".PHP_EOL;
|
||||
//$html .= "act.close();".PHP_EOL;
|
||||
$html .= "alert('$msg');
|
||||
if ('referrer' in document) {
|
||||
window.location = document.referrer;
|
||||
} else {
|
||||
window.history.back();
|
||||
}
|
||||
</script>";
|
||||
|
||||
echo $html;
|
||||
exit;
|
||||
@ -336,8 +354,8 @@ function win_close_alert($msg) {
|
||||
|
||||
?>
|
||||
<script>
|
||||
act = window.open('sms_ing.php', 'act', 'width=300, height=200');
|
||||
act.close();
|
||||
//act = window.open('sms_ing.php', 'act', 'width=300, height=200');
|
||||
//act.close();
|
||||
location.href = 'history_view.php?wr_no=<?php echo $wr_no?>';
|
||||
</script>
|
||||
<?php
|
||||
|
||||
Reference in New Issue
Block a user