【问题标题】:How to disable default payment method (Credit Card) in Stripe Checkout如何在 Stripe Checkout 中禁用默认付款方式(信用卡)
【发布时间】:2017-10-30 05:22:35
【问题描述】:

我只需要一种付款方式(支付宝)。但我无法使用 Stripe Checkout(信用卡)禁用默认付款方式。当然,我读过documentation,但我不知道如何做到这一点。

这是我的代码。

var handler = StripeCheckout.configure({
    key: 'public_key',
    alipay: true,
    locale: false,
    currency: "usd",
    token: function(token) {
        // Use the token to create the charge with a server-side script.
        // You can access the token ID with `token.id`
    }
});

handler.open({
    name: 'example.com',
    description: 'AliPay Payment',
    amount: 10000
});

谢谢!

【问题讨论】:

    标签: javascript stripe-payments stripe.js


    【解决方案1】:

    无法禁用结帐的默认(卡片)区域。

    如果您正在寻找更好的付款方式可定制性,我会查看 Stripe.js/Elements 和 Sources API。您可以使用源 生成支付宝来源,将用户重定向到支付宝以授权支付,然后将其返回到您的网站,https://stripe.com/docs/sources/alipay

    【讨论】:

      猜你喜欢
      • 2021-03-29
      • 2022-01-21
      • 2019-11-11
      • 2021-02-14
      • 1970-01-01
      • 1970-01-01
      • 2023-04-11
      • 2013-09-14
      • 1970-01-01
      相关资源
      最近更新 更多