1. 首页
  2. 编程语言
  3. PHP
  4. 微信端api支付

微信端api支付

上传者: 2019-04-09 23:35:01上传 文件 24KB 热度 38次
//支付源码下载:http://www.sucaihuo.com/php/1196.html public function buildRequestForm(\Think\Pay\PayVo $vo) { $param = array( 'service' => 'create_direct_pay_by_user', 'payment_type' => '1', '_input_charset' => 'utf-8', 'seller_email' => $this->config['email'], 'partner' => $this->config['partner'], 'notify_url' => $this->config['notify_url'], 'return_url' => $this->config['return_url'], 'out_trade_no' => $vo->getOrderNo(), 'subject' => $vo->getTitle(), 'body' => $vo->getBody(), 'total_fee' => $vo->getFee() ); ksort($param); reset($param); $arg = ''; foreach ($param as $key => $value) { if ($value) { $arg .= "$key=$value&"; } } 'seller_email' => $this->config['email'], 'partner' => $this->config['partner'], 'notify_url' => $this->config['notify_url'], 'return_url' => $this->config['return_url'], 'out_trade_no' => $vo->getOrderNo(), 'subject' => $vo->getTitle(), 'body' => $vo->getBody(), 'total_fee' => $vo->getFee() ); ksort($param); reset($param); $arg = ''; foreach ($param as $key => $value) { if ($value) { $arg .= "$key=$value&"; } }
用户评论