<?php
require_once(DEDEMEMBER."/paycenter/cbpayment/cbpayment_config.php");
if($payment_exp[3] < 0) $payment_exp[3] = 0;
$piice_ex = $price*$payment_exp[3];

$v_oid = trim($buyid); //訂單號
if($piice_ex > 0) $price = $price+$piice_ex;
$v_amount = sprintf("%01.2f", $price);                   //支付金額                 

$text = $v_amount.$v_moneytype.$v_oid.$v_mid.$v_url.$key;        //md5加密拼湊串,注意順序不能變
$v_md5info = strtoupper(md5($text));                             //md5函數加密並轉化成大寫字母

$remark1 = trim($ptype);//備註字段1
$remark2 = trim($pname);//備註字段2

$v_rcvname   = '站長';		// 收貨人
$v_rcvaddr   = '深圳';		// 收貨地址
$v_rcvtel    = '0755-83791960';		// 收貨人電話
$v_rcvpost   = '100080';		// 收貨人郵編
$v_rcvmobile = '13838384381';		// 收貨人手機號

$v_ordername   = $cfg_ml->M_UserName;	// 訂貨人姓名
$v_orderaddr   = '深圳';	// 訂貨人地址
$v_ordertel    = '0755-83791960';	// 訂貨人電話
$v_orderpost   = 518000;	// 訂貨人郵編
$v_orderemail  = 'service@nps.cn';	// 訂貨人郵件
$v_ordermobile = 13838384581;	// 訂貨人手機號

$strRequestUrl = $v_post_url.'?v_mid='.$v_mid.'&v_oid='.$v_oid.'&v_amount='.$v_amount.'&v_moneytype='.$v_moneytype
	.'&v_url='.$v_url.'&v_md5info='.$v_md5info.'&remark1='.$remark1.'&remark2='.$remark2;

echo '<html>
<head>
	<title>轉到網銀在線支付頁面</title>
</head>
<body onload="document.cbpayment.submit();">
	<form name="cbpayment" action="'.$strRequestUrl.'" method="post">
	</form>
</body>
</html>';
exit;