php 对接国外支付 ipay88支付

ipay88支付

近期接了一个国外的项目,客户指定要这种支付,就搞搞呗,其实流程和思路都是差不多的,往下看

他的流程其实非常简单  下面的流程仔细看看,看懂了就会了

           1 首先我们需要先获取下单所需要的参数(这个需要去ipay88官网去申请),

            就是下面main.php里面的一些参数merchantCode,merchantKey

           2 参数完整之后我们要做的就是验证签名了(下面有我的验证签名的方式,支付类文件,拿着用就好)

           3 当我们在页面实际付款的时候,我们需要使用一个form表单 post方式执行我们的操作,

            我们需要将签名所需要的参数都以form表单的形式提交到ipay88给我们提供的地址,会自动跳转到支付页(成功唤醒就代表对接成功了)

          4 注意form表单提交的时候,参数一定要完整

          5 测试的时候,ipay88只支持信用卡支付(visa,master),并且支付金额只能为1元

yii-iPay88 API将帮助您为应用程序实现iPay88付款网关。此API中包含以下操作

  • 正常付款
  • 定期付款
  • 定期付款终止
  • 后端通知

认证方式

yii-iPay88 API使用十六进制和base64编码技术来创建唯一签名。然后,此签名将用于客户端的每个请求以及iPay88服务器发送的每个响应。

基本上,此签名基于商户代码,商户密钥,付款金额,货币代码,refno。等。所有API请求都必须通过HTTPS进行。

用法

main.php

‘components‘ => array(
....
‘ipay‘ => array(
        ‘class‘=>‘Ipay‘,
        ‘merchantCode‘=>‘<<merchantCode>>‘,
        ‘merchantKey‘=>‘<<merchantKey>>‘,
        ‘currencyCode‘=>‘MYR‘, // length 5
        ‘responseUrl‘=>‘http://<<hostname>>/ipay/response‘,
        ‘backendUrl‘=>‘http://<<hostname>>/ipaybackend/response‘,
        ‘requeryUrl‘=>‘https://www.mobile88.com/epayment/enquiry.asp‘,
        ‘paymentUrl‘=>‘https://www.mobile88.com/epayment/entry.asp‘,
        ‘recurringUrlSubscription‘=>‘https://www.ipay88.com/recurringpayment/webservice/RecurringPayment.asmx/Subscription‘,
        ‘recurringUrlTermination‘=>‘https://www.ipay88.com/recurringpayment/webservice/RecurringPayment.asmx/Termination‘

    ),
....
)

一个虚拟控制器,演示此组件用于iPay88正常付款的用法并获得该响应,这个也就是你传给支付类文件的参数方法

IpayController.php

class IpayController extends Controller {

    const TRANSACTION_TYPE_PAYMENT = ‘payment‘;
    const TRANSACTION_TYPE_RECURRING_SUBSCRIPTION = ‘recurring_subscription‘;
    const TRANSACTION_TYPE_RECURRING_TERMINATION = ‘recurring_termination‘;

    /*
     * iPay88 normal payment Method
     */
    public function actionPayment() {

        // Unique merchant transaction number / Order ID (Retry for same RefNo only valid for 30 mins). (length 20)
        $paymentParams[‘RefNo‘] = ‘TEST123‘;

        // (Optional) (int)
        $paymentParams[‘PaymentId‘] = ‘2‘;

        // Payment amount with two decimals.
        $paymentParams[‘Amount‘] = ‘1.00‘;

        // Product description. (length 100)
        $paymentParams[‘ProdDesc‘] = ‘This is a test product‘;

        // Customer name. (length 100)
        $paymentParams[‘UserName‘] = ‘Abc‘;

        // Customer email.  (length 100)
        $paymentParams[‘UserEmail‘] = ‘[email protected]‘;

        // Customer contact.  (length 20)
        $paymentParams[‘UserContact‘] = ‘*************‘;

        // (Optional) Merchant remarks. (length 100)
        $paymentParams[‘Remark‘] = ‘Here is the description‘;

        $paymentFields = Yii::app()->ipay->getPaymentFields($paymentParams, self::TRANSACTION_TYPE_PAYMENT);
        $transactionUrl = Yii::app()->ipay->getTransactionUrl(self::TRANSACTION_TYPE_PAYMENT);
        $this->render(‘Payment‘, array(
            ‘paymentFields‘ => $paymentFields,
            ‘transactionUrl‘ => $transactionUrl
        ));
    }

}

/Ipay.php    这个就是你的支付类文件了,用的时候改一下里面的参数就可以,因为这个是基于yii框架的,你可以改一下里面的有些参数,或者删除就好

class Ipay extends CApplicationComponent {

    /**
     * Normal iPay88 payment method
     */
    const TRANSACTION_TYPE_PAYMENT = ‘payment‘;

    /**
     * Normal iPay88 recurring payment subscription
     */
    const TRANSACTION_TYPE_RECURRING_SUBSCRIPTION = ‘recurring_subscription‘;

    /**
     * Normal iPay88 recurring payment termination
     */
    const TRANSACTION_TYPE_RECURRING_TERMINATION = ‘recurring_termination‘;

    /**
     * Merchant code assigned by iPay88
     */
    public $merchantCode;

    /**
     * Merchant Key assigned by iPay88
     */
    public $merchantKey;

    /**
     * Currency Code max length 5
     */
    public $currencyCode;

    /**
     * Merchant code assigned by iPay88
     */
    public $responseUrl;

    /*
     * Response Url or Return Url after payment
     */
    public $paymentUrl;

    /*
     * Backend Url or Notify Url after payment (Send response by iPay88 server)
     */
    public $backendUrl;

    /*
     * Requery from iPay88 server regarding bill details
     */
    public $requeryUrl;

     /*
     * ipay88 Recurring Payment Url
     */
    public $recurringUrlSubscription;

     /*
     * ipay88 Recurring Payment Termination Url
     */
    public $recurringUrlTermination;

    /*
     * Details to be sent to IPay88 for payment request.
     */
    private $paymentRequest = array(
        ‘MerchantCode‘, // Merchant code assigned by iPay88. (length 20)
        ‘PaymentId‘, // (Optional) (int)
        ‘RefNo‘, // Unique merchant transaction number / Order ID (Retry for same RefNo only valid for 30 mins). (length 20)
        ‘Amount‘, // Payment amount with two decimals.
        ‘Currency‘, // (length 5)
        ‘ProdDesc‘, // Product description. (length 100)
        ‘UserName‘, // Customer name. (length 100)
        ‘UserEmail‘, // Customer email.  (length 100)
        ‘UserContact‘, // Customer contact.  (length 20)
        ‘Remark‘, // (Optional) Merchant remarks. (length 100)
        ‘Lang‘, // (Optional) Encoding type:- ISO-8859-1 (English), UTF-8 (Unicode), GB2312 (Chinese Simplified), GD18030 (Chinese Simplified), BIG5 (Chinese Traditional)
        ‘Signature‘,
        ‘ResponseURL‘,
        ‘BackendURL‘,
    );

    /*
     * Details to be sent to iPay88 for recurring subscription payment request.
     */
    private $recurringSubscriptionRequest = array(
        ‘MerchantCode‘, // Merchant code assigned by iPay88. (length 20)
        ‘RefNo‘, // Unique merchant transaction number / Order ID. (length 20)
        ‘FirstPaymentDate‘, // (ddmmyyyy)
        ‘Currency‘, // MYR only. (length 5)
        ‘Amount‘, // Payment amount with two decimals.
        ‘NumberOfPayments‘, // (int)
        ‘Frequency‘, // Frequency type; 1 - Monthly, 2 - Quarterly, 3 - Half-Yearly, 4 - Yearly. (int)
        ‘Desc‘, // Product description. (length 100)
        ‘CC_Name‘, // Name printed on credit card. (length 100)
        ‘CC_PAN‘, // 16-digit credit card number (Visa/Mastercard). (length 16)
        ‘CC_CVC‘, // 3-digit verification code behind credit card. (length 3)
        ‘CC_ExpiryDate‘, // Credit card expiry date. (mmyyyy)
        ‘CC_Country‘, // Credit card issuing country. (length 100)
        ‘CC_Bank‘, // Credit card issuing bank. (length 100)
        ‘CC_Ic‘, // Credit card holder IC / Passport number. (length 50)
        ‘CC_Email‘, // Credit card holder email address. (length 255)
        ‘CC_Phone‘, // Credit card phone number. (length 100)
        ‘CC_Remark‘, // (Optional) Remarks. (varchar 100)
        ‘P_Name‘, // Subscriber name as printed in IC / Passport. (length 100)
        ‘P_Email‘, // Subscriber email address. (length 255)
        ‘P_Phone‘, // Subscriber phone number. (length 100)
        ‘P_Addrl1‘, // Subscriber address line 1. (length 100)
        ‘P_Addrl2‘, // (Optional) Subscriber address line 2. (length 100)
        ‘P_City‘, // Subscriber city. (length 100)
        ‘P_State‘, // Subscriber state. (length 100)
        ‘P_Zip‘, // Subscriber zip code. (length 100)
        ‘P_Country‘, // Subscriber country. (varchar 100)
        ‘BackendURL‘, // Payment backend response page. (length 255)
        ‘Signature‘, // SHA1 signature. (length 100)
    );

    /*
     * Get required payment fields
     */
    public function getPaymentFields($reqParams = null, $paymentType) {
        $retnParams = array();
        try {
            if (isset($reqParams) && (count($reqParams) > 0)) {

                if (isset($paymentType) && $paymentType != "") {
                    $paymentType = strtolower(trim($paymentType));
                    switch ($paymentType) {
                        case ‘payment‘:
                            $retnParams = $this->__getPaymentField($reqParams, $paymentType);
                            break;
                        case ‘recurring_subscription‘:
                            $retnParams = $this->__getRecurringSubscriptionField($reqParams, $paymentType);
                            break;
                        case ‘recurring_termination‘:
                            $retnParams = $this->__getRecurringTerminationField($reqParams, $paymentType);
                            break;
                    }
                } else {
                    throw new Exception("Ipay: Payment method missing");
                }
            } else {
                throw new Exception("Ipay: Required Parameters missing");
            }
        } catch (Exception $e) {
            Yii::log($e->getMessage(), CLogger::LEVEL_ERROR);
        }
        return $retnParams;
    }

    /*
     * Code for hex2bin
     */
    public function _hex2bin($hexSource) {
        $bin = ‘‘;
        for ($i = 0; $i < strlen($hexSource); $i = $i + 2) {
            $bin .= chr(hexdec(substr($hexSource, $i, 2)));
        }
        return $bin;
    }

    /*
     * Get payment fields for normal payment fields
     */
    public function __getPaymentField($reqParams, $paymentType) {
        $retnParams = array();
        foreach ($this->paymentRequest as $pymtKey) {
            if (isset($reqParams[$pymtKey])) {
                $retnParams[$pymtKey] = $reqParams[$pymtKey];
            } else {

                switch ($pymtKey) {
                    case ‘MerchantCode‘:
                        $retnParams[$pymtKey] = $this->merchantCode;
                        break;
                    case ‘Currency‘:
                        $retnParams[$pymtKey] = $this->currencyCode;
                        break;
                    case ‘Lang‘:
                        $retnParams[$pymtKey] = ‘UTF-8‘; //(Optional) Encoding type:- ISO-8859-1 (English), UTF-8 (Unicode), GB2312 (Chinese Simplified), GD18030 (Chinese Simplified), BIG5 (Chinese Traditional)
                        break;
                    case ‘Signature‘:
                        $retnParams[$pymtKey] = $this->__createSignature($retnParams, $paymentType); // SHA1 signature.
                        break;
                    case ‘ResponseURL‘:
                        $retnParams[$pymtKey] = $this->responseUrl; // (Optional) Payment response page.
                        break;
                    case ‘BackendURL‘:
                        $retnParams[$pymtKey] = $this->backendUrl; // (Optional) BackendURL but should security purpose
                        break;
                }
            }
        }

        return $retnParams;
    }

    /*
     * Get payment fields for recurring payment
     */
    public function __getRecurringSubscriptionField($reqParams, $paymentType) {
        $retnParams = array();
        foreach ($this->recurringSubscriptionRequest as $pymtKey) {
            if (isset($reqParams[$pymtKey])) {
                $retnParams[$pymtKey] = $reqParams[$pymtKey];
            } else {

                switch ($pymtKey) {
                    case ‘MerchantCode‘:
                        $retnParams[$pymtKey] = $this->merchantCode;
                        break;
                    case ‘Currency‘:
                        $retnParams[$pymtKey] = $this->currencyCode;
                        break;
                    case ‘Lang‘:
                        $retnParams[$pymtKey] = ‘UTF-8‘; //(Optional) Encoding type:- ISO-8859-1 (English), UTF-8 (Unicode), GB2312 (Chinese Simplified), GD18030 (Chinese Simplified), BIG5 (Chinese Traditional)
                        break;
                    case ‘Signature‘:
                        $retnParams[$pymtKey] = $this->__createSignature($retnParams, $paymentType); // SHA1 signature.
                        break;
                    case ‘ResponseURL‘:
                        $retnParams[$pymtKey] = $this->responseUrl; // (Optional) Payment response page.
                        break;
                    case ‘BackendURL‘:
                        $retnParams[$pymtKey] = $this->backendUrl; // (Optional) BackendURL but should security purpose
                        break;
                }
            }
        }

        return $retnParams;
    }

    /*
     * Get payment fields for recurring payment termination
     */
    public function __getRecurringTerminationField($reqParams, $paymentType) {
        $retnParams = array();
        foreach ($this->recurringSubscriptionRequest as $pymtKey) {
            if (isset($reqParams[$pymtKey])) {
                $retnParams[$pymtKey] = $reqParams[$pymtKey];
            } else {

                switch ($pymtKey) {
                    case ‘MerchantCode‘:
                        $retnParams[$pymtKey] = $this->merchantCode;
                        break;
                }
            }
        }

        return $retnParams;
    }

    /*
     * Create signature for payment
     */
    public function __createSignature($signatureParams, $paymentType) {
        //echo "<pre>";
        //print_r($signatureParams);
        $signature = ‘‘;
        if (isset($signatureParams)) {
            $_signatureParams = array();
            if ($paymentType == self::TRANSACTION_TYPE_PAYMENT) {
                $_signatureParams = array(‘MerchantCode‘, ‘RefNo‘, ‘Amount‘, ‘Currency‘);
            } else if ($paymentType == self::TRANSACTION_TYPE_RECURRING_SUBSCRIPTION) {
                $_signatureParams = array(‘MerchantCode‘, ‘RefNo‘, ‘FirstPaymentDate‘, ‘Currency‘, ‘Amount‘, ‘NumberOfPayments‘, ‘Frequency‘, ‘CC_PAN‘);
            } else if ($paymentType == self::TRANSACTION_TYPE_RECURRING_TERMINATION) {
                $_signatureParams = array(‘MerchantCode‘, ‘RefNo‘);
            }

            foreach ($_signatureParams as $val) {
                if (!isset($signatureParams[$val])) {
                    throw new Exception("Ipay: Missing required parameters for signature.");
                    return false;
                }
            }
        }

        // Make sure the order is correct.
        if ($paymentType == self::TRANSACTION_TYPE_PAYMENT) {
            $signature .= $this->merchantKey;
            $signature .= $signatureParams[‘MerchantCode‘];
            $signature .= $signatureParams[‘PaymentId‘];
            $signature .= $signatureParams[‘RefNo‘];
            $signature .= preg_replace("/[^\d]+/", "", $signatureParams[‘Amount‘]);
            $signature .= $signatureParams[‘Currency‘];
        } else if ($paymentType == self::TRANSACTION_TYPE_RECURRING_SUBSCRIPTION) {
            $signature .= $signatureParams[‘MerchantCode‘];
            $signature .= $this->merchantKey;
            $signature .= $signatureParams[‘RefNo‘];
            $signature .= $signatureParams[‘FirstPaymentDate‘];
            $signature .= $signatureParams[‘Currency‘];
            $signature .= $signatureParams[‘Amount‘];
            $signature .= $signatureParams[‘NumberOfPayments‘];
            $signature .= $signatureParams[‘Frequency‘];
            $signature .= $signatureParams[‘CC_PAN‘];
        } else if ($paymentType == self::TRANSACTION_TYPE_RECURRING_TERMINATION) {
            $signature .= $signatureParams[‘MerchantCode‘];
            $signature .= $this->merchantKey;
            $signature .= $signatureParams[‘RefNo‘];
        }

        // Hash the signature.
        return $signature = base64_encode($this->_hex2bin(sha1($signature)));
    }

    /*
     * Get url for respective payment redirection url
     */
    public function getTransactionUrl($paymentType) {
        if ($paymentType == self::TRANSACTION_TYPE_PAYMENT) {
            return $this->paymentUrl;
        } else if ($paymentType == self::TRANSACTION_TYPE_RECURRING_SUBSCRIPTION) {
            return $this->recurringUrlSubscription;
        } else if ($paymentType == self::TRANSACTION_TYPE_RECURRING_TERMINATION) {
            return $this->recurringUrlTermination;
        }
    }

    /*
     * iPay88 payment signature validation
     */
    public function checkiPay88Signature($reqParams) {
        $status = ‘fail‘;
        try {
            if (isset($reqParams) && count($reqParams) > 0) {
                $orginalKey = $this->merchantKey . $this->merchantCode;
                if (isset($reqParams[‘RefNo‘])) {
                    $orginalKey .=$reqParams[‘RefNo‘];
                }

                if (isset($reqParams[‘Amount‘])) {
                    $orginalKey .=preg_replace("/[^\d]+/", "", $reqParams[‘Amount‘]);
                }
                $orginalKey .= $this->currencyCode;
                if (isset($reqParams[‘Status‘])) {
                    $orginalKey .=$reqParams[‘Status‘];
                }

                $orginalKeyGen = base64_encode($this->_hex2bin(sha1($orginalKey)));
                $returnKey = $this->merchantKey;
                if (isset($reqParams[‘MerchantCode‘])) {
                    $returnKey .=$reqParams[‘MerchantCode‘];
                }

                if (isset($reqParams[‘RefNo‘])) {
                    $returnKey .=$reqParams[‘RefNo‘];
                }
                if (isset($reqParams[‘Amount‘])) {
                    $returnKey .=preg_replace("/[^\d]+/", "", $reqParams[‘Amount‘]);
                }
                if (isset($reqParams[‘Currency‘])) {
                    $returnKey .=$reqParams[‘Currency‘];
                }
                if (isset($reqParams[‘Status‘])) {
                    $returnKey .=$reqParams[‘Status‘];
                }

                $returnKeyGen = base64_encode($this->_hex2bin(sha1($returnKey)));
                if ($orginalKeyGen === $returnKeyGen) {
                    $status = ‘success‘;
                }
            } else {
                throw new Exception("Ipay::checkiPay88Signature: Params missing");
            }
        } catch (exception $e) {
            Yii::log($e->getMessage(), CLogger::LEVEL_ERROR);
        }

        return $status;
    }

    /*
     * Curl hit to get bill deyails
     */
    public function requeryPayment($rawPostData) {
        try {
            $result = ‘‘;
            if (is_callable(‘curl_init‘)) {
                if (isset($rawPostData) && $rawPostData != "") {
                    $ch = curl_init();
                    $url = $this->requeryUrl . ‘?‘ . $rawPostData;
                    curl_setopt($ch, CURLOPT_URL, $url);
                    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
                    $result = curl_exec($ch);
                    curl_close($ch);
                } else {
                    throw new Exception("Ipay::requeryPayment: No request string");
                }
            } else {
                throw new Exception("Ipay::requeryPayment: Curl not enabled");
            }
        } catch (exception $e) {
            Yii::log($e->getMessage(), CLogger::LEVEL_ERROR);
        }

        return $result;
    }

}

views / ipay / payment.php   这个相当于你的回调地址了,下单成功后跳转到这里执行你想要的操作

<?php

$rawPostData = file_get_contents(‘php://input‘);
$resultData = array();
if (strlen($rawPostData) > 0) {
    $rawPostArray = explode(‘&‘, $rawPostData);
    foreach ($rawPostArray as $keyval) {
        $keyval = explode(‘=‘, $keyval);
        if (count($keyval) == 2)
            $resultData[$keyval[0]] = urldecode($keyval[1]);
    }
}
这个就是模拟的form表单了,参照这个提交就没问题了

<FORM method="post" name="ePayment"
action="https://payment.ipay88.com.my/ePayment/entry.asp">
<INPUT type="hidden" name="MerchantCode"  value="M00003">
<INPUT type="hidden" name="PaymentId" value="2">
<INPUT type="hidden" name="RefNo" value="A00000001">
<INPUT type="hidden" name="Amount"  value="1.00">
<INPUT type="hidden" name="Currency"  value="MYR">
<INPUT type="hidden" name="ProdDesc"  value="Photo Print">
<INPUT type="hidden" name="UserName"  value="John Tan">
<INPUT type="hidden" name="UserEmail" value="[email protected]">
<INPUT type="hidden" name="UserContact" value="0126500100">
<INPUT type="hidden" name="Remark"  value="gfdfgd">
<INPUT type="hidden" name="Lang"  value="UTF-8">
<INPUT type="hidden" name="SignatureType" value="SHA256">
<INPUT type="hidden" name="Signature"
value="b81af9c4048b0f6c447129f0f5c0eec8d67cbe19eec26f2cdaba5df4f4dc5a28">
<INPUT type="hidden" name="ResponseURL"
value="http://gx.oeob.net/mobile/respons_ipay.php">
<INPUT type="hidden" name="BackendURL"
value="http://gx.oeob.net/mobile/respons_ipay.php">
<INPUT type="submit" value="Proceed with Payment" name="Submit">
</FORM> 

如果有不明白的地方,评论给我,或者发我邮箱[email protected]

原文地址:https://www.cnblogs.com/bkhdd/p/12215110.html

时间: 2024-10-11 06:20:41

php 对接国外支付 ipay88支付的相关文章

php对接微信小程序支付

前言:这里我就假装你已经注册了微信小程序,并且基本的配置都已经好了.注: 个人注册小程序不支持微信支付,所以我还是假装你是企业或者个体工商户的微信小程序,其他的商户号注册,二者绑定,授权,支付开通,就阅读文档吧,这里我先负责实战. 微信小程序支付开发文档: https://pay.weixin.qq.com/wiki/doc/api/wxa/wxa_api.php?chapter=7_3&index=1 基本流程: 1. 申请商户平台账号 https://pay.weixin.qq.com/in

金融项目股票配资融资融券资金盘专业定制系统搭建支付通道支付渠道支付接口D0实时结算平台第三方支付平台申请对接网银网关

需要了解 JR金融项目 区块链,比特币,p2p项目,B2B网关,现货资金盘,期货招商,股票配资,商品交易所 大盘的 金融支付 第三方支付,网关支付,网银支付,银行卡支付,话费卡支付,银联代扣,支付渠道,支付宝支付,微信支付,扫码支付,快捷支付,支付牌照申请,线上支付通道搭建,支付通道申请,支付接口对接,原生支付宝网关支付!独立后台,D0实时结算,API批量代付接口 JR / BC / QP 菠菜奔驰游戏等稳定安全通道!大量三方支付资质出售!请加QQ 2954704394 随着网络的发展,人们追求

如何申请三方支付接口 微信支付 支付宝支付 网银支付 钱包支付 扫码支付等

如何申请三方支付接口 微信支付 支付宝支付 网银支付 钱包支付  扫码支付等 首先,需要提供一整套申请支付接口的资料,如下 一.企业3证加盖公司公章 二.法人手持身份证照片 三.对应企业ICP备案的交易网站域名 资料审核初步审核之后,请把支付合作协议打印出来一式二份附带企业三证打印盖章邮寄到三方支付公司进一步审核 审核通过后,进行支付接口的对接 联调 最终正式环境上线

聚合支付系统开发,聚合支付引领支付科技

所谓聚合支付,就是依托银行.三方支付或清算组织的支付通道与清算能力,为客户提供接口.集成.对接.订单处理.数据统计等的支付服务机构. 通过锋锐程序搭建的的聚合系统,可实现聚合SDK,聚合支付场景.聚合支付方式.聚合支付通道,无需寻找想要的支付通道.无需重复对接集成繁琐的支付接口,链接商户和通道.降低接入的技术.沟通门槛.降低通道成本,方便快捷的实现支付接入. 聚合支付是移动互联网时代的结构性的支付服务解决方案! 聚合支付的未来不可限量 二维码支付被监管层放开后,移动支付行业增速更加迅猛,行业的发

php大力力 [047节] 支付宝支付.申请支付资质,等待审核中

https://beecloud.cn/doc/payapply/?index=6 支付宝支付申请支付资质 一.注册支付宝用户 在支付宝官网注册成为用户 二.签约对应支付产品 应用集成支付宝支付,需要签约支付宝支付产品. 荷马史诗,西西弗斯是人间最足智多谋又机巧的人,他是科林斯的建城者和国王.当宙斯掳走河神伊索普斯(Aesopus)的女儿伊琴娜(Aegina),河神曾到科林斯找寻其女,知悉此事的西西弗斯以一条四季常流的河川做为交换条件告知.由于泄露了宙斯的秘密,宙斯便派出死神要将他押下地狱.没有

微信支付,支付宝支付,银联支付——三大支付总结

转载:  https://juejin.im/post/596d97576fb9a06bb874a812 银联支付,支付宝支付,微信支付的三大总结,之前也有写过两篇. 微信支付,支付宝支付,银联支付--三大支付总结: http://blog.csdn.net/androidstarjack/article/details/72669394 支付宝植入总结: android 支付宝的植入 <曾经踩过的坑> 微信支付总结: Android 微信支付总结 备注:出于安全考虑,验签我们都是放到后台进行

《聊一聊关于微信、支付宝、银联支付故事 --- 支付坑的故事》

支付坑的故事 -最主要的是微信 ,以下都是自己的思考得来的,难免有不足之处.如有错误,欢迎给位批评指正!也可在下面留下你的QQ 咱们一起讨论问题! 总结:楼主感觉微信支付是最坑人的-没有之一! 1:微信支付步骤如下:微信支付原理:https://pay.weixin.qq.com/wiki/doc/api/app.php?chapter=8_3 统一下单接口:https://pay.weixin.qq.com/wiki/doc/api/app.php?chapter=9_1   可以查看那些是必

微信支付出现支付请求参数错误,请核实再试或交易出错,请稍后再试的可能原因

微信支付经常会出现有些奇怪找不到原因的问题,下面就是其中的一个例子当你的微信支付出现 “支付请求参数错误,请核实再试”或 “交易出错,请稍后再试”的错误的时候,不访从下面几点找原因1,确保你的微信的app_id,app_secret,parent_id,parent_key,parent_sign_key的信息是否填写正确了.2,请检查package的参数是否错误或为空等情况,具体设置可参考开发文档.3,微信的金额是以分为单位的,所以请检查一下你传入的金额最小值是不是大于1(千万不要传小数点进去

微信支付-JSAPI支付V3-发起一次支付请求

JSAPI支付业务流程:图片来源于:http://pay.weixin.qq.com/wiki/doc/api/index.php?chapter=7_4 准备工作:需要先在项目中引用Senparc.WeiXin.dll和Senparc.WeiXin.MP.dll,开源项目见:https://github.com/JeffreySu/WeiXinMPSDK 第一步:绑定域名 先登录微信公众平台进入“公众号设置”的“功能设置”里填写“JS接口安全域名”. 第二步:引入JS文件 在需要调用JS接口的