Reputation: 574
I'm using Braintree Js V2 hosted field and paypal in ruby rails form. everything works fine, however is there any way to add space between numbers in credit card and insert " / " in expiration fields like Js V3 does?
However, I tried JS V3 hosted fields combined with paypal as explained here https://github.com/braintree/braintree-web/issues/209 as I want the customer to remain on site rather than a re direct to paypal - cannot figure out how to pass payment_method_nonce in submit form function.
For v3 Im using Material Design example form in braintree guides
Do I have to create hidden field in the form to pass payment_method_nonce in submit function ?
Upvotes: 0
Views: 284
Reputation: 896
Full disclosure: I work at Braintree. If you have any further questions, feel free to contact support.
Input formatting isn't supported for Hosted Fields in Braintree's JSv2 SDK. Check out the conversation about this exact topic in this GitHub issue.
Regarding your question about how to submit the nonce: you will need to append a hidden field to your form whose value is the nonce. Check out the Hosted Fields example on the braintree-web GitHub repo.
Upvotes: 1