Payment by PayPal Login works but direct by debit/credit card doesn't
malaypdoshi
Contributor
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Posted on
Apr-27-2021
02:31 AM
The issue is quite weird. The PayPal integration is successful. The payment happen with proper flow when a user logs into PayPal and pays. But if one tries to pay by debit card without logging into PayPal, it shows a white screen.
I am trying to make payment using PayPal Guest Checkout, but it does not work on Live environment but Works fine on Sandbox Environment.
In the Live Environment, the user tries the guest checkout without login. The details are accepted from the user, after which the OTP from the bank is successfully received, When submitting the OTP for verification, the Website loads back to the PayPal URL & gets stuck at a white screen.
The Feature "Login with PayPal" works perfectly fine on both environments
Also, "PayPal Account Optional" feature turned to "On" for Accepting the Payments from Guests.
Front End Technology Used: ReactJS
NPM Package Used: react-paypal-button-v2
Code Part for PayPal Button:
//total - Total amount to be paid
//paypalID - Client Id from App
<PayPalButton
amount={total.toFixed(2)}
style={{ label: 'pay' }}
options={{
clientId: paypalID,
currency: 'USD'
}}
shippingPreference="NO_SHIPPING"
onSuccess={(details, data) => {
//On Success Here
}}
onError={(err) => {
//On Error Here
}}
onCancel={(data) => {
//On Cancel Here
}}
createOrder={(data, actions) => {
return actions.order.create({
purchase_units: [
{
amount: {
value: total.toFixed(2)
}
}
]
});
}}
/>
amount={total.toFixed(2)}
style={{ label: 'pay' }}
options={{
clientId: paypalID,
currency: 'USD'
}}
shippingPreference="NO_SHIPPING"
onSuccess={(details, data) => {
//On Success Here
}}
onError={(err) => {
//On Error Here
}}
onCancel={(data) => {
//On Cancel Here
}}
createOrder={(data, actions) => {
return actions.order.create({
purchase_units: [
{
amount: {
value: total.toFixed(2)
}
}
]
});
}}
/>
Require help at the earliest
0 REPLIES 0
Haven't Found your Answer?
It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.
Related Content
- Sandbox testing has beaten me !! in Sandbox Environment
- Customising Paypal Checkout Button in PayPal Payments Standard
- recurring payments when price maybe changed and price have 2 decimal point in REST APIs
- Paypal express checkout, payment they error "Sorry, something went wrong. Please try again." in PayPal Payments Standard
- Add Others data in SDKs