【问题标题】:How can I work with Paypal sandbox mode in CI Merchant如何在 CI Merchant 中使用 Paypal 沙盒模式
【发布时间】:2015-08-25 19:00:03
【问题描述】:

我正在为Paypal Express 使用以下代码。

$settings = array(
            'username' => 'XXXX',
            'password' => 'XXX',
            'signature' => 'XXXX',
            'test_mode' => TRUE
        );

当我使用上面的代码时,显示以下错误消息

Merchant_response Object
(
    [_status:protected] => failed
    [_message:protected] => Security header is not valid
    [_reference:protected] => 
    [_data:protected] => 
    [_redirect_url:protected] => 
    [_redirect_method:protected] => GET
    [_redirect_message:protected] => 
    [_redirect_data:protected] => 
)

但是,如果我将 test_mode 更改为 false,它的工作正常(重定向到 paypal 支付页面)。谁能告诉我如何工作 test_mode?​​p>

我使用以下步骤创建了我的 API

 Profile -> My Selling Tools -> Selling Online – API Access -> Update -> 
Request API Credentials – Request API signature -> Agree and Submit 

在创建 API 时,我在哪里指定了 Sandbox mode?

【问题讨论】:

  • 我使用沙盒或测试模式的实时模式 api 详细信息犯了错误。转到您的开发人员贝宝帐户并选择业务并转到您的个人资料页面。沙盒或测试模式 API 详细信息在 API 凭据点击中指定。

标签: php codeigniter paypal paypal-sandbox


【解决方案1】:

你好,你应该使用环境并将其设置为沙盒

$settings = array(
            'username' => 'XXXX',
            'password' => 'XXX',
            'signature' => 'XXXX',
            'test_mode' => TRUE,
            'environment'=>'sandbox'
);

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2014-08-28
    • 2012-08-31
    • 2011-08-24
    • 2013-09-02
    • 2014-10-20
    • 2013-01-10
    • 2013-01-22
    • 2015-11-01
    相关资源
    最近更新 更多