관리자 LMS 모듈 적용
This commit is contained in:
@ -26,17 +26,44 @@ if ($w == "u")
|
||||
|
||||
// SMS 알림
|
||||
if($config['cf_sms_use'] == 'icode' && $row['iq_hp']) {
|
||||
include_once(G5_LIB_PATH.'/icode.sms.lib.php');
|
||||
|
||||
$sms_content = get_text($row['it_name']).' 상품문의에 답변이 등록되었습니다.';
|
||||
$send_number = preg_replace('/[^0-9]/', '', $default['de_admin_company_tel']);
|
||||
$recv_number = preg_replace('/[^0-9]/', '', $row['iq_hp']);
|
||||
|
||||
if($recv_number) {
|
||||
$SMS = new SMS; // SMS 연결
|
||||
$SMS->SMS_con($config['cf_icode_server_ip'], $config['cf_icode_id'], $config['cf_icode_pw'], $config['cf_icode_server_port']);
|
||||
$SMS->Add($recv_number, $send_number, $config['cf_icode_id'], iconv("utf-8", "euc-kr", stripslashes($sms_content)), "");
|
||||
$SMS->Send();
|
||||
if($config['cf_sms_type'] == 'LMS') {
|
||||
include_once(G5_LIB_PATH.'/icode.lms.lib.php');
|
||||
|
||||
$port_setting = get_icode_port_type($config['cf_icode_id'], $config['cf_icode_pw']);
|
||||
|
||||
// SMS 모듈 클래스 생성
|
||||
if($port_setting !== false) {
|
||||
$SMS = new LMS;
|
||||
$SMS->SMS_con($config['cf_icode_server_ip'], $config['cf_icode_id'], $config['cf_icode_pw'], $port_setting);
|
||||
|
||||
$strDest = array();
|
||||
$strDest[] = $recv_number;
|
||||
$strCallBack = $send_number;
|
||||
$strCaller = iconv_euckr(trim($default['de_admin_company_name']));
|
||||
$strSubject = '';
|
||||
$strURL = '';
|
||||
$strData = iconv_euckr($sms_content);
|
||||
$strDate = '';
|
||||
$nCount = count($strDest);
|
||||
|
||||
$res = $SMS->Add($strDest, $strCallBack, $strCaller, $strSubject, $strURL, $strData, $strDate, $nCount);
|
||||
|
||||
$SMS->Send();
|
||||
$SMS->Init(); // 보관하고 있던 결과값을 지웁니다.
|
||||
}
|
||||
} else {
|
||||
include_once(G5_LIB_PATH.'/icode.sms.lib.php');
|
||||
|
||||
$SMS = new SMS; // SMS 연결
|
||||
$SMS->SMS_con($config['cf_icode_server_ip'], $config['cf_icode_id'], $config['cf_icode_pw'], $config['cf_icode_server_port']);
|
||||
$SMS->Add($recv_number, $send_number, $config['cf_icode_id'], iconv_euckr(stripslashes($sms_content)), "");
|
||||
$SMS->Send();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user