#an2one_paypal-redirect
1 messages ¡ Page 1 of 1 (latest)
đ Welcome to your new thread!
â˛ď¸ We'll be here soon! We typically respond in a few minutes, but in some cases we might need a bit more time (e.g., server's busy, you've got a complex question, etc.).
âąď¸ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can start a new thread if you have another question.
đ This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1260653869613060137
đ Have more to share? Add details, code, screenshots, videos, etc. below.
@modern cobalt I'm sorry I don't really get your question and what is the problem.
When you pay with Paypal you get redirected to Paypal. So if the payment succeeds or fails you have already left your page with PaymentElement. Your customer will always be sent back to the return_url you configured
an2one_paypal-redirect
return_url in my case is the url with thank you for your order page, inestad of redirecting there in case of failure I want to keep user on payment page
I understand you want that, but it's impossible. So really, in your return_url, check if the payment succeeded or not. If it did, send them to the thank you page, if it didn't send them back to your page showing PaymentElement
How can I verify if payment succeeded or not?
Call the Retrieve PaymentIntent API https://docs.stripe.com/api/payment_intents/retrieve and check the status
Let me verify if works as expected