$val){ $content .= "{$key}={$val}&"; } $content .= "key=".config::KEY; return strtoupper(md5($content)); } public function add($card_no,$card_type,$amount,$input) { $params = $this->req_params($card_no,$card_type,$amount,$input); $sign = $this->sign($params); $params['sign'] = $sign; $resp = http_request(config::ORDER_URL,$params,'POST',false, config::ExtHeaders); if($resp === false) { return [false,'系统错误']; } else { Log::record($resp,Log::DEBUG); $resp = json_decode($resp,true); if($resp['code'] == 200) { return [true,$resp['msg']]; } else { return [false,$resp['msg']]; } } } public function query($refill_info) { } }