How to disable the new "Standard Card Fields" behavior in my PayPal Smart buttons integration
See original GitHub issueDescription
The recent updates on PayPal Smart Buttons have introduced a new feature called “Standard Card Fields”. So now, if a user tries to make a payment with a card, it renders an iframe to collect card and billing info of customer inline on the page instead of a guest checkout popup. However, there is no way to change the appearance/style of the card form to match with the rest of my checkout form and the behavior is inconsistent since, for some, it still opens up in a guess checkout modal.
What I want is a way to disable the standard card fields and this new inline behavior and want my integration to follow the old behavior which opens up a guest checkout modal on clicking on a card option. Looking at the sample code here https://developer.paypal.com/docs/checkout/integration-features/standard-card-fields/#best-practices, there is a parameter passed enableStandardCardFields: true,
and I have tried to pass it has enableStandardCardFields: false,
but it still follow the new inline checkout behavior.
Please lemme know if there is a way to completely disable this new behavior without disabling the card options itself–I don’t want to disable the card options but wanna keep the old guest checkout behavior for card payments until there comes a way to style the checkout fields to match rest of my form.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:4
- Comments:13
I switched to Stripe to solve this issue
not sure if anyone still having this issue, but I was able to fix it by adding
ref: https://developer.paypal.com/docs/checkout/integration-features/standalone-buttons/#render-a-set-of-buttons