diff --git a/Application/Callback/Controller/NotifyController.class.php b/Application/Callback/Controller/NotifyController.class.php index 8d0fe52..3caae94 100644 --- a/Application/Callback/Controller/NotifyController.class.php +++ b/Application/Callback/Controller/NotifyController.class.php @@ -932,11 +932,9 @@ class NotifyController extends BaseController * 酷点回调 */ public function kd_callback() { - $params = I('post.'); + $params = file_get_contents('php://input'); KDLog::write('NOTIFY_INPUT:' . file_get_contents('php://input')); - KDLog::write('NOTIFY_POST:' . json_encode($params)); - KDLog::write('NOTIFY_REQUEST:' . json_encode($_REQUEST)); $response = new KDResponse($params); if (!$response->verify()) { diff --git a/Application/Sdk/Controller/PayH5Controller.class.php b/Application/Sdk/Controller/PayH5Controller.class.php index 9e7c3c3..b4df446 100644 --- a/Application/Sdk/Controller/PayH5Controller.class.php +++ b/Application/Sdk/Controller/PayH5Controller.class.php @@ -539,7 +539,7 @@ class PayH5Controller extends BaseController{ $notifyUrl = C('PAY_DOMAIN')."/callback.php/Notify/kd_callback"; $backUrl = C('PAY_DOMAIN')."sdk.php/Spend/paycallback/orderno/{$request['pay_order_number']}/user_token/".$this->userToken."/paytype/weixinpay/game_id/{$game_id}"; $body = '消费-' . $request["pay_order_number"]; - $response = KDApi::h5Pay($request['pay_order_number'], $request['price']*100, $notifyUrl, $backUrl, 'ALI_PAY', $body, get_client_ip()); + $response = KDApi::h5Pay($request['pay_order_number'], $request['price']*100, $notifyUrl, $backUrl, 'ALIPAY', $body, get_client_ip()); if($response->isSuccess()){ // 存入pay_url 继续支付 @@ -874,7 +874,7 @@ class PayH5Controller extends BaseController{ $notifyUrl = C('PAY_DOMAIN')."/callback.php/Notify/kd_callback"; $backUrl = C('PAY_DOMAIN')."sdk.php/Spend/paycallback/orderno/{$request['pay_order_number']}/user_token/".$this->userToken."/paytype/weixinpay/game_id/{$game_id}"; $body = '消费-' . $request["pay_order_number"]; - $response = KDApi::h5Pay($request['pay_order_number'], $request['price']*100, $notifyUrl, $backUrl, 'WX_PAY', $body, get_client_ip()); + $response = KDApi::h5Pay($request['pay_order_number'], $request['price']*100, $notifyUrl, $backUrl, 'WXPAY', $body, get_client_ip()); if($response->isSuccess()){ // 存入pay_url 继续支付