프리샵 추가
4
shop/kcp/_common.php
Normal file
@ -0,0 +1,4 @@
|
||||
<?
|
||||
$g4_path = "../..";
|
||||
include_once("$g4_path/common.php");
|
||||
?>
|
||||
BIN
shop/kcp/bin/pp_cli
Normal file
122
shop/kcp/css/index.css
Normal file
@ -0,0 +1,122 @@
|
||||
BODY
|
||||
{
|
||||
}
|
||||
|
||||
td {font-family: "<22><><EFBFBD><EFBFBD>", "<22><><EFBFBD><EFBFBD>ü", Arial, Verdana;font-size: 9pt;color: #000000;}
|
||||
|
||||
/*<2A>̹<EFBFBD><CCB9><EFBFBD>*/
|
||||
.indexbox {background-image: url('../img/index_bg_box.jpg');padding-top: 58px;padding-right: 27px;padding-bottom: 27px;padding-left: 27px;}
|
||||
.indexgen {background-image: url(../img/index_gen.jpg);background-repeat: no-repeat;}
|
||||
.indexescrow {background-image: url(../img/index_escrow.jpg);}
|
||||
.indexcms {background-image: url(../img/index_cms.jpg);}
|
||||
.line1 {background-image: url(../img/line_dot1.gif);background-repeat: repeat;height:1px;}
|
||||
.bulgen {background-image: url(../img/bul_gen.gif);background-repeat: no-repeat;}
|
||||
.bulescrow {background-image: url(../img/bul_escrow.gif);background-repeat: no-repeat;}
|
||||
.bulcms {background-image: url(../img/bul_cms.gif);background-repeat: no-repeat;}
|
||||
.boxtop589 {background-image: url(../img/boxtop589.gif);background-repeat: no-repeat;}
|
||||
.boxbtm589 {background-image: url(../img/boxbtm589.gif);background-repeat: no-repeat;}
|
||||
.boxbg589 {background-image: url(../img/boxbg589.gif);background-repeat: repeat;}
|
||||
.ttbg551 {background-image: url(../img/ttbg551.gif);background-repeat: no-repeat;padding-left: 18px;}
|
||||
.ttbtm551 {background-image: url(../img/ttbg551.gif);background-repeat: no-repeat;padding-left: 18px;}
|
||||
.boxbg551 {background-image: url(../img/boxbg551.gif);background-repeat: repeat;padding:18 18 18 18;}
|
||||
.boxbtm551 {background-image: url(../img/boxbtm551.gif);background-repeat: no-repeat;}
|
||||
img { border: 0px; margin: 0px; padding: 0px;} /* img border 0 */
|
||||
|
||||
/*<2A><><EFBFBD>̺<EFBFBD>*/
|
||||
.tbtop {background-color: #0f75ac;background-repeat: repeat;}
|
||||
.tbleft {background-repeat: no-repeat;background-image: url(../img/tb_left.gif);height: 27px;color: #003b7e;width: 139px;padding:3 0 0 25;}
|
||||
.tbline {background-color: #bbcbdb;background-repeat: repeat;}
|
||||
.tbline2 {background-color: #a3ccf3;background-repeat: repeat;}
|
||||
.padding12{padding-left: 12px;}
|
||||
|
||||
|
||||
/*<2A><>Ʈ*/
|
||||
.bold {font-weight: bold;}
|
||||
.white {color: #ffffff;}
|
||||
.orange {color: orange;}
|
||||
.red {color: red;}
|
||||
.tt12{ font-size: 12pt; color: #ffffff;font-weight: bold;}
|
||||
|
||||
.linkb{ font-size: 9pt; color: #000000;font-weight: bold;text-decoration: none;}
|
||||
.linkb a:link{ font-size: 9pt; color: #000000;font-weight: bold;text-decoration: none;}
|
||||
.linkb a:visited{ font-size: 9pt; color: #000000;font-weight: bold;text-decoration: none;}
|
||||
.linkb a:hover{ font-size: 9pt; color: #000000;font-weight: bold;text-decoration: none;}
|
||||
|
||||
/*FORM*/
|
||||
.form { font-size: 9pt; background-color: #FFFFFF; color: #2c2c2c; border: 1 solid #7f9db9; padding:3 0 0 3; height: 20px}
|
||||
.formwon {font-size: 9pt;background-color: #FFFFFF;color: #2c2c2c; border: 1 solid #7f9db9; padding:3 0 0 3; height: 20px;text-align: right;}
|
||||
|
||||
/*
|
||||
##### title #####
|
||||
*/
|
||||
#main_link
|
||||
{
|
||||
|
||||
top:17%;
|
||||
left:50%;
|
||||
|
||||
margin-left:-130px;
|
||||
margin-top:20px;
|
||||
|
||||
position:absolute;
|
||||
}
|
||||
|
||||
#main_link ul
|
||||
{
|
||||
list-style-type:none;
|
||||
}
|
||||
|
||||
.title
|
||||
{
|
||||
font-family:"<22><><EFBFBD><EFBFBD>";
|
||||
font-size: 12pt;
|
||||
font-weight: bold;
|
||||
|
||||
padding-left:20px;
|
||||
background: url(../img/bul_gen.gif) no-repeat 0 50%;
|
||||
}
|
||||
|
||||
.sub
|
||||
{
|
||||
font-family:"<22><><EFBFBD><EFBFBD>";
|
||||
font-size: 9pt;
|
||||
color: #3f3f3f;
|
||||
padding-left:20px;
|
||||
}
|
||||
|
||||
/*
|
||||
##### background image #####
|
||||
*/
|
||||
#bg_image
|
||||
{
|
||||
position:absolute;
|
||||
|
||||
width: 602px;
|
||||
height:400px;
|
||||
|
||||
top:10%;
|
||||
left:50%;
|
||||
|
||||
margin-left: -301px;
|
||||
|
||||
}
|
||||
|
||||
#left_bg
|
||||
{
|
||||
float: left;
|
||||
|
||||
width:160px;
|
||||
height:400px;
|
||||
|
||||
background-image: url("../img/index_gen.jpg");
|
||||
list-style-type:none;
|
||||
}
|
||||
|
||||
#right_bg
|
||||
{
|
||||
float: left;
|
||||
width:432px;
|
||||
height:400px;
|
||||
background-image: url("../img/index_bg_box.jpg");
|
||||
list-style-type:none;
|
||||
}
|
||||
81
shop/kcp/css/sample.css
Normal file
@ -0,0 +1,81 @@
|
||||
body {FONT-FAMILY: <EFBFBD><EFBFBD><EFBFBD><EFBFBD>;font-size:12px;}
|
||||
|
||||
/*base link*/
|
||||
a {FONT-FAMILY: "Arial", "<22><><EFBFBD><EFBFBD>"; font-size: 12px; TEXT-DECORATION: none}
|
||||
a:hover {FONT-FAMILY: "Arial",<EFBFBD><EFBFBD><EFBFBD><EFBFBD>; FONT-SIZE: 12px; color: #4D82A2; TEXT-DECORATION:none}
|
||||
|
||||
img { border:0; }
|
||||
.bold {font-weight:bold;}
|
||||
.white {color:white;}
|
||||
.big {font-size:12pt;}
|
||||
.align_left {text-align: left;}
|
||||
.right {text-align: right;}
|
||||
.red { color:red;}
|
||||
.blue { color:blue;}
|
||||
.orange {color:orange;}
|
||||
.frmselect {font-size:12px;font-family:"Arial",<EFBFBD><EFBFBD><EFBFBD><EFBFBD>;color:#2c2c2c;border:1 solid #7f9db9;height:20px;margin-left:10px;}
|
||||
.frminput {font-size:12px;font-family:"Arial",<EFBFBD><EFBFBD><EFBFBD><EFBFBD>;color:#2c2c2c;border:1 solid #7f9db9;height:15px;margin-left:10px;}
|
||||
.width95 {width:95px;}
|
||||
.celpadd {padding: 3 0 3 3;}
|
||||
.celpadd1 {padding: 3 0 3 13;}
|
||||
|
||||
.line1 { width:1px; background-color:#bbcbdb; }
|
||||
.line2 { height:1px; background-color:#bbcbdb; }
|
||||
|
||||
.height_1px { height:1px; }
|
||||
.height_2px { height:2px; }
|
||||
|
||||
.margin_top_20 { margin-top:20px; }
|
||||
.margin_top_10 { margin-top:10px; }
|
||||
|
||||
.title
|
||||
{
|
||||
height:20px;
|
||||
font-family:"Arial";
|
||||
font-size: 9pt;
|
||||
font-weight: bold;
|
||||
|
||||
color:#003b7e;
|
||||
text-align:center;
|
||||
|
||||
border-bottom: 1px solid #0f75ac ;
|
||||
border-top: 1px solid #0f75ac ;
|
||||
}
|
||||
|
||||
.sub_title1 {
|
||||
width:150px;
|
||||
font-size:12px;
|
||||
height:20px;
|
||||
padding: 3 0 3 3;
|
||||
background-color:#e6f3f4;
|
||||
background-image:url("./img/bullet.gif") ;
|
||||
color:#003b7e;
|
||||
margin-left:10px;
|
||||
border-bottom: 1px solid #bbcbdb ;
|
||||
text-align:center;
|
||||
}
|
||||
|
||||
.sub_input1 {
|
||||
font-size:12px;
|
||||
height:20px;
|
||||
padding: 3 0 3 3;
|
||||
text-align:left;
|
||||
border-bottom: 1px solid #bbcbdb ;
|
||||
}
|
||||
|
||||
.sub_content1 {
|
||||
font-size:12px;
|
||||
padding: 3 0 3 3;
|
||||
text-align:left;
|
||||
text-indent:10px;
|
||||
border-bottom: 1px solid #bbcbdb ;
|
||||
}
|
||||
|
||||
.sub_content1_center {
|
||||
font-size:12px;
|
||||
padding: 3 0 3 3;
|
||||
text-align:center;
|
||||
border-bottom: 1px solid #bbcbdb ;
|
||||
}
|
||||
|
||||
|
||||
BIN
shop/kcp/img/KcpLogo.jpg
Normal file
|
After Width: | Height: | Size: 26 KiB |
BIN
shop/kcp/img/Thumbs.db
Normal file
BIN
shop/kcp/img/boxbg551.gif
Normal file
|
After Width: | Height: | Size: 70 B |
BIN
shop/kcp/img/boxbg589.gif
Normal file
|
After Width: | Height: | Size: 68 B |
BIN
shop/kcp/img/boxbtm551.gif
Normal file
|
After Width: | Height: | Size: 432 B |
BIN
shop/kcp/img/boxbtm589.gif
Normal file
|
After Width: | Height: | Size: 1022 B |
BIN
shop/kcp/img/boxtop589.gif
Normal file
|
After Width: | Height: | Size: 454 B |
BIN
shop/kcp/img/btn_buy.gif
Normal file
|
After Width: | Height: | Size: 3.7 KiB |
BIN
shop/kcp/img/btn_cancel.gif
Normal file
|
After Width: | Height: | Size: 3.7 KiB |
BIN
shop/kcp/img/btn_certi.gif
Normal file
|
After Width: | Height: | Size: 3.7 KiB |
BIN
shop/kcp/img/btn_change.gif
Normal file
|
After Width: | Height: | Size: 3.7 KiB |
BIN
shop/kcp/img/btn_close.gif
Normal file
|
After Width: | Height: | Size: 3.1 KiB |
BIN
shop/kcp/img/btn_home.gif
Normal file
|
After Width: | Height: | Size: 3.6 KiB |
BIN
shop/kcp/img/btn_issue.gif
Normal file
|
After Width: | Height: | Size: 3.7 KiB |
BIN
shop/kcp/img/btn_key.gif
Normal file
|
After Width: | Height: | Size: 4.0 KiB |
BIN
shop/kcp/img/btn_ok.gif
Normal file
|
After Width: | Height: | Size: 3.1 KiB |
BIN
shop/kcp/img/btn_pay.gif
Normal file
|
After Width: | Height: | Size: 3.7 KiB |
BIN
shop/kcp/img/btn_receipt.gif
Normal file
|
After Width: | Height: | Size: 4.0 KiB |
BIN
shop/kcp/img/btn_regi.gif
Normal file
|
After Width: | Height: | Size: 3.6 KiB |
BIN
shop/kcp/img/btn_save.gif
Normal file
|
After Width: | Height: | Size: 3.7 KiB |
BIN
shop/kcp/img/btn_search.gif
Normal file
|
After Width: | Height: | Size: 3.6 KiB |
BIN
shop/kcp/img/bul_cms.gif
Normal file
|
After Width: | Height: | Size: 144 B |
BIN
shop/kcp/img/bul_escrow.gif
Normal file
|
After Width: | Height: | Size: 144 B |
BIN
shop/kcp/img/bul_gen.gif
Normal file
|
After Width: | Height: | Size: 144 B |
BIN
shop/kcp/img/bullet.gif
Normal file
|
After Width: | Height: | Size: 57 B |
BIN
shop/kcp/img/dot_line.gif
Normal file
|
After Width: | Height: | Size: 73 B |
BIN
shop/kcp/img/index_bg_box.jpg
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
shop/kcp/img/index_cms.jpg
Normal file
|
After Width: | Height: | Size: 20 KiB |
BIN
shop/kcp/img/index_escrow.jpg
Normal file
|
After Width: | Height: | Size: 21 KiB |
BIN
shop/kcp/img/index_gen.jpg
Normal file
|
After Width: | Height: | Size: 20 KiB |
BIN
shop/kcp/img/kcp_ing.gif
Normal file
|
After Width: | Height: | Size: 24 KiB |
BIN
shop/kcp/img/kcp_plug_bg01.gif
Normal file
|
After Width: | Height: | Size: 70 B |
BIN
shop/kcp/img/kcp_plug_img01.gif
Normal file
|
After Width: | Height: | Size: 18 KiB |
BIN
shop/kcp/img/kcp_plug_img02.gif
Normal file
|
After Width: | Height: | Size: 188 B |
BIN
shop/kcp/img/kcp_plug_img03.gif
Normal file
|
After Width: | Height: | Size: 4.7 KiB |
BIN
shop/kcp/img/kcp_plug_img04.gif
Normal file
|
After Width: | Height: | Size: 213 B |
BIN
shop/kcp/img/kcp_plug_img05.gif
Normal file
|
After Width: | Height: | Size: 508 B |
BIN
shop/kcp/img/line_dot1.gif
Normal file
|
After Width: | Height: | Size: 44 B |
BIN
shop/kcp/img/processing.gif
Normal file
|
After Width: | Height: | Size: 12 KiB |
BIN
shop/kcp/img/tb_left.gif
Normal file
|
After Width: | Height: | Size: 161 B |
BIN
shop/kcp/img/tt_order1.gif
Normal file
|
After Width: | Height: | Size: 496 B |
BIN
shop/kcp/img/ttbg551.gif
Normal file
|
After Width: | Height: | Size: 12 KiB |
416
shop/kcp/pp_ax_hub.php
Normal file
@ -0,0 +1,416 @@
|
||||
<?
|
||||
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
|
||||
|
||||
/* ============================================================================== */
|
||||
/* = PAGE : 지불 요청 및 결과 처리 PAGE = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 연동시 오류가 발생하는 경우 아래의 주소로 접속하셔서 확인하시기 바랍니다.= */
|
||||
/* = 접속 주소 : http://testpay.kcp.co.kr/pgsample/FAQ/search_error.jsp = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = Copyright (c) 2010.02 KCP Inc. All Rights Reserved. = */
|
||||
/* ============================================================================== */
|
||||
|
||||
|
||||
/* ============================================================================== */
|
||||
/* = 환경 설정 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
|
||||
$g_conf_home_dir = dirname($_SERVER['DOCUMENT_ROOT'] . $_SERVER['PHP_SELF']) . '/kcp/';
|
||||
$g_conf_key_dir = '';
|
||||
$g_conf_log_dir = '';
|
||||
if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN')
|
||||
{
|
||||
$g_conf_key_dir = dirname($_SERVER['DOCUMENT_ROOT'] . $_SERVER['PHP_SELF']) . '/kcp/bin/pub.key';
|
||||
$g_conf_log_dir = dirname($_SERVER['DOCUMENT_ROOT'] . $_SERVER['PHP_SELF']) . '/kcp/log';
|
||||
}
|
||||
|
||||
$g_conf_site_cd = $_POST['site_cd'];
|
||||
|
||||
if (preg_match("/^T000/", $g_conf_site_cd) || $default['de_card_test']) {
|
||||
$g_conf_gw_url = "testpaygw.kcp.co.kr"; // real url : paygw.kcp.co.kr , test url : testpaygw.kcp.co.kr
|
||||
}
|
||||
else {
|
||||
$g_conf_gw_url = "paygw.kcp.co.kr";
|
||||
if (!preg_match("/^SR/", $g_conf_site_cd)) {
|
||||
alert("SR 로 시작하지 않는 KCP SITE CODE 는 지원하지 않습니다.");
|
||||
}
|
||||
}
|
||||
|
||||
$g_conf_log_level = "3"; // 변경불가
|
||||
$g_conf_gw_port = "8090"; // 포트번호(변경불가)
|
||||
|
||||
require "pp_ax_hub_lib.php"; // library [수정불가]
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 환경 설정 파일 Include END = */
|
||||
/* ============================================================================== */
|
||||
?>
|
||||
|
||||
<?
|
||||
/* ============================================================================== */
|
||||
/* = 01. 지불 요청 정보 설정 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$req_tx = $_POST[ "req_tx" ]; // 요청 종류
|
||||
$tran_cd = $_POST[ "tran_cd" ]; // 처리 종류
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$cust_ip = getenv( "REMOTE_ADDR" ); // 요청 IP
|
||||
$ordr_idxx = $_POST[ "ordr_idxx" ]; // 쇼핑몰 주문번호
|
||||
$good_name = addslashes($_POST[ "good_name"]); // 상품명
|
||||
$good_mny = $_POST[ "good_mny" ]; // 결제 총금액
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$res_cd = ""; // 응답코드
|
||||
$res_msg = ""; // 응답메시지
|
||||
$res_en_msg = ""; // 응답 영문 메세지
|
||||
$tno = $_POST[ "tno" ]; // KCP 거래 고유 번호
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$buyr_name = addslashes($_POST[ "buyr_name"]); // 주문자명
|
||||
$buyr_tel1 = $_POST[ "buyr_tel1" ]; // 주문자 전화번호
|
||||
$buyr_tel2 = $_POST[ "buyr_tel2" ]; // 주문자 핸드폰 번호
|
||||
$buyr_mail = $_POST[ "buyr_mail" ]; // 주문자 E-mail 주소
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$mod_type = $_POST[ "mod_type" ]; // 변경TYPE VALUE 승인취소시 필요
|
||||
$mod_desc = $_POST[ "mod_desc" ]; // 변경사유
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$use_pay_method = $_POST[ "use_pay_method" ]; // 결제 방법
|
||||
$bSucc = ""; // 업체 DB 처리 성공 여부
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$app_time = ""; // 승인시간 (모든 결제 수단 공통)
|
||||
$amount = ""; // KCP 실제 거래 금액
|
||||
$total_amount = 0; // 복합결제시 총 거래금액
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$card_cd = ""; // 신용카드 코드
|
||||
$card_name = ""; // 신용카드 명
|
||||
$app_no = ""; // 신용카드 승인번호
|
||||
$noinf = ""; // 신용카드 무이자 여부
|
||||
$quota = ""; // 신용카드 할부개월
|
||||
$partcanc_yn = ""; // 부분취소 가능유무
|
||||
$card_bin_type_01 = ""; // 카드구분1
|
||||
$card_bin_type_01 = ""; // 카드구분2
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$bank_name = ""; // 은행명
|
||||
$bank_code = ""; // 은행코드
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$bankname = ""; // 입금할 은행명
|
||||
$depositor = ""; // 입금할 계좌 예금주 성명
|
||||
$account = ""; // 입금할 계좌 번호
|
||||
$va_date = ""; // 가상계좌 입금마감시간
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$pnt_issue = ""; // 결제 포인트사 코드
|
||||
$pt_idno = ""; // 결제 및 인증 아이디
|
||||
$pnt_amount = ""; // 적립금액 or 사용금액
|
||||
$pnt_app_time = ""; // 승인시간
|
||||
$pnt_app_no = ""; // 승인번호
|
||||
$add_pnt = ""; // 발생 포인트
|
||||
$use_pnt = ""; // 사용가능 포인트
|
||||
$rsv_pnt = ""; // 총 누적 포인트
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$commid = ""; // 통신사 코드
|
||||
$mobile_no = ""; // 휴대폰 번호
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$tk_shop_id = $_POST[ "tk_shop_id" ]; // 가맹점 고객 아이디
|
||||
$tk_van_code = ""; // 발급사 코드
|
||||
$tk_app_no = ""; // 상품권 승인 번호
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$cash_yn = $_POST[ "cash_yn" ]; // 현금영수증 등록 여부
|
||||
$cash_authno = ""; // 현금 영수증 승인 번호
|
||||
$cash_tr_code = $_POST[ "cash_tr_code" ]; // 현금 영수증 발행 구분
|
||||
$cash_id_info = $_POST[ "cash_id_info" ]; // 현금 영수증 등록 번호
|
||||
/* ============================================================================== */
|
||||
/* = 01-1. 에스크로 지불 요청 정보 설정 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$escw_used = $_POST[ "escw_used" ]; // 에스크로 사용 여부
|
||||
$pay_mod = $_POST[ "pay_mod" ]; // 에스크로 결제처리 모드
|
||||
$deli_term = $_POST[ "deli_term" ]; // 배송 소요일
|
||||
$bask_cntx = $_POST[ "bask_cntx" ]; // 장바구니 상품 개수
|
||||
$good_info = $_POST[ "good_info" ]; // 장바구니 상품 상세 정보
|
||||
$rcvr_name = addslashes($_POST[ "rcvr_name"]); // 수취인 이름
|
||||
$rcvr_tel1 = $_POST[ "rcvr_tel1" ]; // 수취인 전화번호
|
||||
$rcvr_tel2 = $_POST[ "rcvr_tel2" ]; // 수취인 휴대폰번호
|
||||
$rcvr_mail = $_POST[ "rcvr_mail" ]; // 수취인 E-Mail
|
||||
$rcvr_zipx = $_POST[ "rcvr_zipx" ]; // 수취인 우편번호
|
||||
$rcvr_add1 = addslashes($_POST[ "rcvr_add1"]); // 수취인 주소
|
||||
$rcvr_add2 = addslashes($_POST[ "rcvr_add2"]); // 수취인 상세주소
|
||||
$escw_yn = ""; // 에스크로 여부
|
||||
|
||||
/* ============================================================================== */
|
||||
|
||||
/* ============================================================================== */
|
||||
/* = 02. 인스턴스 생성 및 초기화 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 결제에 필요한 인스턴스를 생성하고 초기화 합니다. = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$c_PayPlus = new C_PP_CLI;
|
||||
|
||||
$c_PayPlus->mf_clear();
|
||||
/* ------------------------------------------------------------------------------ */
|
||||
/* = 02. 인스턴스 생성 및 초기화 END = */
|
||||
/* ============================================================================== */
|
||||
|
||||
|
||||
/* ============================================================================== */
|
||||
/* = 03. 처리 요청 정보 설정 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 03-1. 승인 요청 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
if ( $req_tx == "pay" )
|
||||
{
|
||||
/* 1004원은 실제로 업체에서 결제하셔야 될 원 금액을 넣어주셔야 합니다. 결제금액 유효성 검증 */
|
||||
$c_PayPlus->mf_set_ordr_data( "ordr_mony", $good_mny );
|
||||
|
||||
$c_PayPlus->mf_set_encx_data( $_POST[ "enc_data" ], $_POST[ "enc_info" ] );
|
||||
}
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 03-2. 취소/매입 요청 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
else if ( $req_tx == "mod" )
|
||||
{
|
||||
$tran_cd = "00200000";
|
||||
|
||||
$c_PayPlus->mf_set_modx_data( "tno", $tno ); // KCP 원거래 거래번호
|
||||
$c_PayPlus->mf_set_modx_data( "mod_type", $mod_type ); // 원거래 변경 요청 종류
|
||||
$c_PayPlus->mf_set_modx_data( "mod_ip", $cust_ip ); // 변경 요청자 IP
|
||||
$c_PayPlus->mf_set_modx_data( "mod_desc", $mod_desc ); // 변경 사유
|
||||
}
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 03-3. 에스크로 상태변경 요청 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
else if ($req_tx = "mod_escrow")
|
||||
{
|
||||
$tran_cd = "00200000";
|
||||
|
||||
$c_PayPlus->mf_set_modx_data( "tno", $tno ); // KCP 원거래 거래번호
|
||||
$c_PayPlus->mf_set_modx_data( "mod_type", $mod_type ); // 원거래 변경 요청 종류
|
||||
$c_PayPlus->mf_set_modx_data( "mod_ip", $cust_ip ); // 변경 요청자 IP
|
||||
$c_PayPlus->mf_set_modx_data( "mod_desc", $mod_desc ); // 변경 사유
|
||||
|
||||
if ($mod_type == "STE1") // 상태변경 타입이 [배송요청]인 경우
|
||||
{
|
||||
$c_PayPlus->mf_set_modx_data( "deli_numb", $_POST[ "deli_numb" ] ); // 운송장 번호
|
||||
$c_PayPlus->mf_set_modx_data( "deli_corp", $_POST[ "deli_corp" ] ); // 택배 업체명
|
||||
}
|
||||
else if ($mod_type == "STE2" || $mod_type == "STE4") // 상태변경 타입이 [즉시취소] 또는 [취소]인 계좌이체, 가상계좌의 경우
|
||||
{
|
||||
if ($vcnt_yn == "Y")
|
||||
{
|
||||
$c_PayPlus->mf_set_modx_data( "refund_account", $_POST[ "refund_account" ] ); // 환불수취계좌번호
|
||||
$c_PayPlus->mf_set_modx_data( "refund_nm", $_POST[ "refund_nm" ] ); // 환불수취계좌주명
|
||||
$c_PayPlus->mf_set_modx_data( "bank_code", $_POST[ "bank_code" ] ); // 환불수취은행코드
|
||||
}
|
||||
}
|
||||
}
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 03-3. 에스크로 상태변경 요청 END = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
|
||||
/* ------------------------------------------------------------------------------ */
|
||||
/* = 03. 처리 요청 정보 설정 END = */
|
||||
/* ============================================================================== */
|
||||
|
||||
|
||||
|
||||
/* ============================================================================== */
|
||||
/* = 04. 실행 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
if ( $tran_cd != "" )
|
||||
{
|
||||
$c_PayPlus->mf_do_tx( $trace_no, $g_conf_home_dir, $g_conf_site_cd, "", $tran_cd, "",
|
||||
$g_conf_gw_url, $g_conf_gw_port, "payplus_cli_slib", $ordr_idxx,
|
||||
$cust_ip, "3" , 0, 0, $g_conf_key_dir, $g_conf_log_dir); // 응답 전문 처리
|
||||
|
||||
$res_cd = $c_PayPlus->m_res_cd; // 결과 코드
|
||||
$res_msg = $c_PayPlus->m_res_msg; // 결과 메시지
|
||||
/* $res_en_msg = $c_PayPlus->mf_get_res_data( "res_en_msg" ); // 결과 영문 메세지 */
|
||||
}
|
||||
else
|
||||
{
|
||||
$c_PayPlus->m_res_cd = "9562";
|
||||
$c_PayPlus->m_res_msg = "연동 오류|Payplus Plugin이 설치되지 않았거나 tran_cd값이 설정되지 않았습니다.";
|
||||
}
|
||||
|
||||
if ($res_cd != '0000')
|
||||
{
|
||||
if (strtolower($g4[charset]) == "utf-8")
|
||||
{
|
||||
$res_msg = iconv("euc-kr", "utf-8", $res_msg);
|
||||
}
|
||||
|
||||
echo "<script>
|
||||
var openwin = window.open( './kcp/proc_win.php', 'proc_win', '' );
|
||||
openwin.close();
|
||||
</script>";
|
||||
alert("$res_cd : $res_msg");
|
||||
exit;
|
||||
}
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 04. 실행 END = */
|
||||
/* ============================================================================== */
|
||||
|
||||
|
||||
/* ============================================================================== */
|
||||
/* = 05. 승인 결과 값 추출 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
if ( $req_tx == "pay" )
|
||||
{
|
||||
if( $res_cd == "0000" )
|
||||
{
|
||||
$tno = $c_PayPlus->mf_get_res_data( "tno" ); // KCP 거래 고유 번호
|
||||
$amount = $c_PayPlus->mf_get_res_data( "amount" ); // KCP 실제 거래 금액
|
||||
$pnt_issue = $c_PayPlus->mf_get_res_data( "pnt_issue" ); // 결제 포인트사 코드
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 05-1. 신용카드 승인 결과 처리 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
if ( $use_pay_method == "100000000000" )
|
||||
{
|
||||
$card_cd = $c_PayPlus->mf_get_res_data( "card_cd" ); // 카드사 코드
|
||||
$card_name = $c_PayPlus->mf_get_res_data( "card_name" ); // 카드 종류
|
||||
$app_time = $c_PayPlus->mf_get_res_data( "app_time" ); // 승인 시간
|
||||
$app_no = $c_PayPlus->mf_get_res_data( "app_no" ); // 승인 번호
|
||||
$noinf = $c_PayPlus->mf_get_res_data( "noinf" ); // 무이자 여부 ( 'Y' : 무이자 )
|
||||
$quota = $c_PayPlus->mf_get_res_data( "quota" ); // 할부 개월 수
|
||||
$partcanc_yn = $c_PayPlus->mf_get_res_data( "partcanc_yn" ); // 부분취소 가능유무
|
||||
$card_bin_type_01 = $c_PayPlus->mf_get_res_data( "card_bin_type_01" ); // 카드구분1
|
||||
$card_bin_type_02 = $c_PayPlus->mf_get_res_data( "card_bin_type_02" ); // 카드구분2
|
||||
|
||||
/* = -------------------------------------------------------------- = */
|
||||
/* = 05-1.1. 복합결제(포인트+신용카드) 승인 결과 처리 = */
|
||||
/* = -------------------------------------------------------------- = */
|
||||
if ( $pnt_issue == "SCSK" || $pnt_issue == "SCWB" )
|
||||
{
|
||||
$pt_idno = $c_PayPlus->mf_get_res_data ( "pt_idno" ); // 결제 및 인증 아이디
|
||||
$pnt_amount = $c_PayPlus->mf_get_res_data ( "pnt_amount" ); // 적립금액 or 사용금액
|
||||
$pnt_app_time = $c_PayPlus->mf_get_res_data ( "pnt_app_time" ); // 승인시간
|
||||
$pnt_app_no = $c_PayPlus->mf_get_res_data ( "pnt_app_no" ); // 승인번호
|
||||
$add_pnt = $c_PayPlus->mf_get_res_data ( "add_pnt" ); // 발생 포인트
|
||||
$use_pnt = $c_PayPlus->mf_get_res_data ( "use_pnt" ); // 사용가능 포인트
|
||||
$rsv_pnt = $c_PayPlus->mf_get_res_data ( "rsv_pnt" ); // 총 누적 포인트
|
||||
$total_amount = $amount + $pnt_amount; // 복합결제시 총 거래금액
|
||||
}
|
||||
}
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 05-2. 계좌이체 승인 결과 처리 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
if ( $use_pay_method == "010000000000" )
|
||||
{
|
||||
$app_time = $c_PayPlus->mf_get_res_data( "app_time" ); // 승인 시간
|
||||
$bank_name = $c_PayPlus->mf_get_res_data( "bank_name" ); // 은행명
|
||||
$bank_code = $c_PayPlus->mf_get_res_data( "bank_code" ); // 은행코드
|
||||
}
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 05-3. 가상계좌 승인 결과 처리 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
if ( $use_pay_method == "001000000000" )
|
||||
{
|
||||
$bankname = $c_PayPlus->mf_get_res_data( "bankname" ); // 입금할 은행 이름
|
||||
$depositor = $c_PayPlus->mf_get_res_data( "depositor" ); // 입금할 계좌 예금주
|
||||
$account = $c_PayPlus->mf_get_res_data( "account" ); // 입금할 계좌 번호
|
||||
$va_date = $c_PayPlus->mf_get_res_data( "va_date" ); // 가상계좌 입금마감시간
|
||||
}
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 05-4. 포인트 승인 결과 처리 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
if ( $use_pay_method == "000100000000" )
|
||||
{
|
||||
$pt_idno = $c_PayPlus->mf_get_res_data( "pt_idno" ); // 결제 및 인증 아이디
|
||||
$pnt_amount = $c_PayPlus->mf_get_res_data( "pnt_amount" ); // 적립금액 or 사용금액
|
||||
$pnt_app_time = $c_PayPlus->mf_get_res_data( "pnt_app_time" ); // 승인시간
|
||||
$pnt_app_no = $c_PayPlus->mf_get_res_data( "pnt_app_no" ); // 승인번호
|
||||
$add_pnt = $c_PayPlus->mf_get_res_data( "add_pnt" ); // 발생 포인트
|
||||
$use_pnt = $c_PayPlus->mf_get_res_data( "use_pnt" ); // 사용가능 포인트
|
||||
$rsv_pnt = $c_PayPlus->mf_get_res_data( "rsv_pnt" ); // 적립 포인트
|
||||
}
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 05-5. 휴대폰 승인 결과 처리 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
if ( $use_pay_method == "000010000000" )
|
||||
{
|
||||
$app_time = $c_PayPlus->mf_get_res_data( "hp_app_time" ); // 승인 시간
|
||||
$commid = $c_PayPlus->mf_get_res_data( "commid" ); // 통신사 코드
|
||||
$mobile_no = $c_PayPlus->mf_get_res_data( "mobile_no" ); // 휴대폰 번호
|
||||
}
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 05-6. 상품권 승인 결과 처리 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
if ( $use_pay_method == "000000001000" )
|
||||
{
|
||||
$app_time = $c_PayPlus->mf_get_res_data( "tk_app_time" ); // 승인 시간
|
||||
$tk_van_code = $c_PayPlus->mf_get_res_data( "tk_van_code" ); // 발급사 코드
|
||||
$tk_app_no = $c_PayPlus->mf_get_res_data( "tk_app_no" ); // 승인 번호
|
||||
}
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 05-7. 현금영수증 결과 처리 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$cash_yn = $c_PayPlus->mf_get_res_data( "cash_yn" ); // 현금영수증 등록여부
|
||||
$cash_authno = $c_PayPlus->mf_get_res_data( "cash_authno" ); // 현금 영수증 승인 번호
|
||||
$cash_tr_code = $c_PayPlus->mf_get_res_data( "cash_tr_code" ); // 현금영수증 등록구분
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 05-8. 에스크로 여부 결과 처리 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
$escw_yn = $c_PayPlus->mf_get_res_data( "escw_yn" ); // 에스크로 여부
|
||||
}
|
||||
}
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 05. 승인 결과 처리 END = */
|
||||
/* ============================================================================== */
|
||||
|
||||
/* ============================================================================== */
|
||||
/* = 06. 승인 및 실패 결과 DB처리 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 결과를 업체 자체적으로 DB처리 작업하시는 부분입니다. = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
|
||||
if ( $req_tx == "pay" )
|
||||
{
|
||||
if( $res_cd == "0000" )
|
||||
{
|
||||
// 06-1-1. 신용카드
|
||||
if ( $use_pay_method == "100000000000" )
|
||||
{
|
||||
// 06-1-1-1. 복합결제(신용카드 + 포인트)
|
||||
if ( $pnt_issue == "SCSK" || $pnt_issue == "SCWB" )
|
||||
{
|
||||
}
|
||||
}
|
||||
// 06-1-2. 계좌이체
|
||||
if ( $use_pay_method == "010000000000" )
|
||||
{
|
||||
}
|
||||
// 06-1-3. 가상계좌
|
||||
if ( $use_pay_method == "001000000000" )
|
||||
{
|
||||
}
|
||||
// 06-1-4. 포인트
|
||||
if ( $use_pay_method == "000100000000" )
|
||||
{
|
||||
}
|
||||
// 06-1-5. 휴대폰
|
||||
if ( $use_pay_method == "000010000000" )
|
||||
{
|
||||
}
|
||||
// 06-1-6. 상품권
|
||||
if ( $use_pay_method == "000000001000" )
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 06. 승인 및 실패 결과 DB처리 = */
|
||||
/* ============================================================================== */
|
||||
else if ( $res_cd != "0000" )
|
||||
{
|
||||
}
|
||||
}
|
||||
?>
|
||||
73
shop/kcp/pp_ax_hub_cancel.php
Normal file
@ -0,0 +1,73 @@
|
||||
<?
|
||||
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
|
||||
|
||||
/* ============================================================================== */
|
||||
/* = 07. 승인 결과 DB처리 실패시 : 자동취소 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 승인 결과를 DB 작업 하는 과정에서 정상적으로 승인된 건에 대해 = */
|
||||
/* = DB 작업을 실패하여 DB update 가 완료되지 않은 경우, 자동으로 = */
|
||||
/* = 승인 취소 요청을 하는 프로세스가 구성되어 있습니다. = */
|
||||
/* = = */
|
||||
/* = DB 작업이 실패 한 경우, bSucc 라는 변수(String)의 값을 "false" = */
|
||||
/* = 로 설정해 주시기 바랍니다. (DB 작업 성공의 경우에는 "false" 이외의 = */
|
||||
/* = 값을 설정하시면 됩니다.) = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
|
||||
$bSucc = "false"; // DB 작업 실패 또는 금액 불일치의 경우 "false" 로 세팅
|
||||
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 07-1. DB 작업 실패일 경우 자동 승인 취소 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
if ( $req_tx == "pay" )
|
||||
{
|
||||
if( $res_cd == "0000" )
|
||||
{
|
||||
if ( $bSucc == "false" )
|
||||
{
|
||||
$c_PayPlus->mf_clear();
|
||||
|
||||
$tran_cd = "00200000";
|
||||
|
||||
/* ============================================================================== */
|
||||
/* = 07-1.자동취소시 에스크로 거래인 경우 = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
// 취소시 사용하는 mod_type
|
||||
$bSucc_mod_type = "";
|
||||
|
||||
// 에스크로 가상계좌 건의 경우 가상계좌 발급취소(STE5)
|
||||
if ( $escw_yn == "Y" && $use_pay_method == "001000000000" )
|
||||
{
|
||||
$bSucc_mod_type = "STE5";
|
||||
}
|
||||
// 에스크로 가상계좌 이외 건은 즉시취소(STE2)
|
||||
else if ( $escw_yn == "Y" )
|
||||
{
|
||||
$bSucc_mod_type = "STE2";
|
||||
}
|
||||
// 에스크로 거래 건이 아닌 경우(일반건)(STSC)
|
||||
else
|
||||
{
|
||||
$bSucc_mod_type = "STSC";
|
||||
}
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = 07-1. 자동취소시 에스크로 거래인 경우 처리 END = */
|
||||
/* = ========================================================================== = */
|
||||
|
||||
$c_PayPlus->mf_set_modx_data( "tno", $tno ); // KCP 원거래 거래번호
|
||||
$c_PayPlus->mf_set_modx_data( "mod_type", $bSucc_mod_type ); // 원거래 변경 요청 종류
|
||||
$c_PayPlus->mf_set_modx_data( "mod_ip", $cust_ip ); // 변경 요청자 IP
|
||||
$c_PayPlus->mf_set_modx_data( "mod_desc", "가맹점 결과 처리 오류 - 가맹점에서 취소 요청" ); // 변경 사유
|
||||
|
||||
$c_PayPlus->mf_do_tx( $tno, $g_conf_home_dir, $g_conf_site_cd,
|
||||
"", $tran_cd, "",
|
||||
$g_conf_gw_url, $g_conf_gw_port, "payplus_cli_slib",
|
||||
$ordr_idxx, $cust_ip, "3" ,
|
||||
0, 0, $g_conf_key_dir, $g_conf_log_dir);
|
||||
|
||||
$res_cd = $c_PayPlus->m_res_cd;
|
||||
$res_msg = $c_PayPlus->m_res_msg;
|
||||
}
|
||||
}
|
||||
} // End of [res_cd = "0000"]
|
||||
/* ============================================================================== */
|
||||
?>
|
||||
260
shop/kcp/pp_ax_hub_lib.php
Normal file
@ -0,0 +1,260 @@
|
||||
<?
|
||||
/* ============================================================================== */
|
||||
/* = PAGE : <20><><EFBFBD>̺<EFBFBD><CCBA><EFBFBD><EFBFBD><EFBFBD> PAGE = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = Copyright (c) 2010.02 KCP Inc. All Rights Reserverd. = */
|
||||
/* ============================================================================== */
|
||||
|
||||
/* ============================================================================== */
|
||||
/* = <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> CLASS = */
|
||||
/* ============================================================================== */
|
||||
class C_PP_CLI
|
||||
{
|
||||
var $m_payx_common;
|
||||
var $m_payx_card;
|
||||
var $m_ordr_data;
|
||||
var $m_rcvr_data;
|
||||
var $m_escw_data;
|
||||
var $m_modx_data;
|
||||
var $m_encx_data;
|
||||
var $m_encx_info;
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/* - ó<><C3B3> <20><><EFBFBD><EFBFBD> <20><> - */
|
||||
/* -------------------------------------------------------------------- */
|
||||
var $m_res_data;
|
||||
var $m_res_cd;
|
||||
var $m_res_msg;
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/* - <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> - */
|
||||
/* -------------------------------------------------------------------- */
|
||||
function C_PP_CLI()
|
||||
{
|
||||
$this->m_payx_common = "";
|
||||
$this->m_payx_card = "";
|
||||
$this->m_ordr_data = "";
|
||||
$this->m_rcvr_data = "";
|
||||
$this->m_escw_data = "";
|
||||
$this->m_modx_data = "";
|
||||
$this->m_encx_data = "";
|
||||
$this->m_encx_info = "";
|
||||
}
|
||||
|
||||
function mf_init( $mode )
|
||||
{
|
||||
if ( $mode == "1" )
|
||||
{
|
||||
if ( !extension_loaded( 'pp_cli_dl_php' ) )
|
||||
{
|
||||
dl( "pp_cli_dl_php.so" );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function mf_clear()
|
||||
{
|
||||
$this->m_payx_common = "";
|
||||
$this->m_payx_card = "";
|
||||
$this->m_ordr_data = "";
|
||||
$this->m_rcvr_data = "";
|
||||
$this->m_escw_data = "";
|
||||
$this->m_modx_data = "";
|
||||
$this->m_encx_data = "";
|
||||
$this->m_encx_info = "";
|
||||
}
|
||||
|
||||
function mf_gen_trace_no( $site_cd, $ip, $mode )
|
||||
{
|
||||
if ( $mode == "1" )
|
||||
{
|
||||
$trace_no = lfPP_CLI_DL__gen_trace_no( $site_cd, $ip );
|
||||
}
|
||||
else
|
||||
{
|
||||
$trace_no = "";
|
||||
}
|
||||
|
||||
return $trace_no;
|
||||
}
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/* - FUNC : ENC DATA <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20>Լ<EFBFBD> - */
|
||||
/* -------------------------------------------------------------------- */
|
||||
function mf_set_payx_common_data( $name, $val )
|
||||
{
|
||||
if ( $val != "" )
|
||||
{
|
||||
$this->m_payx_common .= ( $name . '=' . $val . chr( 31 ) );
|
||||
}
|
||||
}
|
||||
|
||||
function mf_set_payx_card_data( $name, $val )
|
||||
{
|
||||
if ( $val != "" )
|
||||
{
|
||||
$this->m_payx_card .= ( $name . '=' . $val . chr( 31 ) );
|
||||
}
|
||||
}
|
||||
|
||||
function mf_set_ordr_data( $name, $val )
|
||||
{
|
||||
if ( $val != "" )
|
||||
{
|
||||
$this->m_ordr_data .= ( $name . '=' . $val . chr( 31 ) );
|
||||
}
|
||||
}
|
||||
|
||||
function mf_set_rcvr_data( $name, $val )
|
||||
{
|
||||
if ( $val != "" )
|
||||
{
|
||||
$this->m_rcvr_data .= ( $name . '=' . $val . chr( 31 ) );
|
||||
}
|
||||
}
|
||||
|
||||
function mf_set_escw_data( $name, $val )
|
||||
{
|
||||
if ( $val != "" )
|
||||
{
|
||||
$this->m_escw_data .= ( $name . '=' . $val . chr( 29 ) );
|
||||
}
|
||||
}
|
||||
|
||||
function mf_set_modx_data( $name, $val )
|
||||
{
|
||||
if ( $val != "" )
|
||||
{
|
||||
$this->m_modx_data .= ( $name . '=' . $val . chr( 31 ) );
|
||||
}
|
||||
}
|
||||
|
||||
function mf_set_encx_data( $encx_data, $encx_info )
|
||||
{
|
||||
$this->m_encx_data = $encx_data;
|
||||
$this->m_encx_info = $encx_info;
|
||||
}
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/* - FUNC : <20><><EFBFBD><EFBFBD> ó<><C3B3> <20>Լ<EFBFBD> - */
|
||||
/* -------------------------------------------------------------------- */
|
||||
function mf_do_tx( $trace_no, $home_dir, $site_cd,
|
||||
$site_key, $tx_cd, $pub_key_str,
|
||||
$pa_url, $pa_port, $user_agent,
|
||||
$ordr_idxx, $cust_ip,
|
||||
$log_level, $opt, $mode )
|
||||
{
|
||||
$payx_data = $this->mf_get_payx_data();
|
||||
|
||||
$ordr_data = $this->mf_get_data( "ordr_data", $this->m_ordr_data );
|
||||
$rcvr_data = $this->mf_get_data( "rcvr_data", $this->m_rcvr_data );
|
||||
$escw_data = $this->mf_get_data( "escw_data", $this->m_escw_data );
|
||||
$modx_data = $this->mf_get_data( "mod_data", $this->m_modx_data );
|
||||
|
||||
if ( $mode == "1" )
|
||||
{
|
||||
$res_data = lfPP_CLI_DL__do_tx_2( $trace_no, $home_dir, $site_cd,
|
||||
$site_key, $tx_cd, $pub_key_str,
|
||||
$pa_url, $pa_port, $user_agent,
|
||||
$ordr_idxx,
|
||||
$payx_data, $ordr_data,
|
||||
$rcvr_data, $escw_data,
|
||||
$modx_data,
|
||||
$this->m_encx_data, $this->m_encx_info,
|
||||
$log_level, $opt );
|
||||
}
|
||||
else
|
||||
{
|
||||
$res_data = $this->mf_exec( $home_dir . "/bin/pp_cli",
|
||||
"-h",
|
||||
"home=" . $home_dir . "," .
|
||||
"site_cd=" . $site_cd . "," .
|
||||
"site_key=" . $site_key . "," .
|
||||
"tx_cd=" . $tx_cd . "," .
|
||||
"pa_url=" . $pa_url . "," .
|
||||
"pa_port=" . $pa_port . "," .
|
||||
"ordr_idxx=" . $ordr_idxx . "," .
|
||||
"payx_data=" . $payx_data . "," .
|
||||
"ordr_data=" . $ordr_data . "," .
|
||||
"rcvr_data=" . $rcvr_data . "," .
|
||||
"escw_data=" . $escw_data . "," .
|
||||
"modx_data=" . $modx_data . "," .
|
||||
"enc_data=" . $this->m_encx_data . "," .
|
||||
"enc_info=" . $this->m_encx_info . "," .
|
||||
"trace_no=" . $trace_no . "," .
|
||||
"cust_ip=" . $cust_ip . "," .
|
||||
"log_level=" . $log_level . "," .
|
||||
"opt=" . $opt . "" );
|
||||
if ( $res_data == "" )
|
||||
{
|
||||
$res_data = "res_cd=9502" . chr( 31 ) . "res_msg=<3D><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> ȣ<><C8A3> <20><><EFBFBD><EFBFBD>";
|
||||
}
|
||||
}
|
||||
|
||||
parse_str( str_replace( chr( 31 ), "&", $res_data ), $this->m_res_data );
|
||||
|
||||
$this->m_res_cd = $this->m_res_data[ "res_cd" ];
|
||||
$this->m_res_msg = $this->m_res_data[ "res_msg" ];
|
||||
}
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/* - FUNC : ó<><C3B3> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>ϴ<EFBFBD> <20>Լ<EFBFBD> - */
|
||||
/* -------------------------------------------------------------------- */
|
||||
function mf_get_res_data( $name )
|
||||
{
|
||||
return $this->m_res_data[ $name ];
|
||||
}
|
||||
|
||||
function mf_get_payx_data()
|
||||
{
|
||||
if ( $this->m_payx_common != "" || $this->m_payx_card != "" )
|
||||
{
|
||||
$my_data = "payx_data=";
|
||||
}
|
||||
|
||||
if ( $this->m_payx_common != "" )
|
||||
{
|
||||
$my_data .= "common=" . $this->m_payx_common . chr( 30 );
|
||||
}
|
||||
|
||||
if ( $this->m_payx_card != "" )
|
||||
{
|
||||
$my_data .= ( "card=" . $this->m_payx_card . chr( 30 ) );
|
||||
}
|
||||
|
||||
return $my_data;
|
||||
}
|
||||
|
||||
function mf_get_data( $data_name, $data )
|
||||
{
|
||||
if ( $data != "" )
|
||||
{
|
||||
$my_data = $data_name . "=" . $data;
|
||||
}
|
||||
else
|
||||
{
|
||||
$my_data = "";
|
||||
}
|
||||
|
||||
return $my_data;
|
||||
}
|
||||
|
||||
function mf_exec()
|
||||
{
|
||||
$arg = func_get_args();
|
||||
|
||||
if ( is_array( $arg[0] ) ) $arg = $arg[0];
|
||||
|
||||
$exec_cmd = array_shift( $arg );
|
||||
|
||||
while ( list(,$i) = each($arg) )
|
||||
{
|
||||
$exec_cmd .= " " . escapeshellarg( $i );
|
||||
}
|
||||
|
||||
$rt = exec( $exec_cmd );
|
||||
|
||||
return $rt;
|
||||
}
|
||||
}
|
||||
?>
|
||||
17
shop/kcp/proc_win.html
Normal file
@ -0,0 +1,17 @@
|
||||
<!--
|
||||
/* ============================================================================== */
|
||||
/* = PAGE : <20><><EFBFBD><EFBFBD>â <20><><EFBFBD><EFBFBD> PAGE = */
|
||||
/* = -------------------------------------------------------------------------- = */
|
||||
/* = Copyright (c) 2010.02 KCP Inc. All Rights Reserverd. = */
|
||||
/* ============================================================================== */
|
||||
//-->
|
||||
<html>
|
||||
<head>
|
||||
<title> ó<><C3B3><EFBFBD><EFBFBD> </title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=euc-kr">
|
||||
<meta http-equiv="ImageToolbar" content="No">
|
||||
</head>
|
||||
<body leftmargin="0" topmargin="0" onBlur="window.document.pro.focus();">
|
||||
<img src="./img/processing.gif" name="pro">
|
||||
</body>
|
||||
</html>
|
||||