Skip to content

Commit

Permalink
交易关闭接口
Browse files Browse the repository at this point in the history
  • Loading branch information
dedemao authored Jun 1, 2020
1 parent 79d1fa9 commit 3b4e222
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions close.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class AlipayService

public function __construct()
{
$this->charset = 'utf8';
$this->charset = 'utf-8';
}
public function setAppid($appid)
{
Expand Down Expand Up @@ -81,7 +81,7 @@ public function doClose()
'biz_content'=>json_encode($requestConfigs),
);
$commonConfigs["sign"] = $this->generateSign($commonConfigs, $commonConfigs['sign_type']);
$result = $this->curlPost('https://openapi.alipay.com/gateway.do',$commonConfigs);
$result = $this->curlPost('https://openapi.alipay.com/gateway.do?charset='.$this->charset,$commonConfigs);
$resultArr = json_decode($result,true);
if(empty($resultArr)){
$result = iconv('GBK','UTF-8//IGNORE',$result);
Expand Down

0 comments on commit 3b4e222

Please sign in to comment.