Aditya Singh
Dec 26, 2018 · 1 min read

I have used Stripe which uses somewhat similar pop up for payments.

Follow below steps:

  1. Get the id of the button that triggers the popup.
  2. Do document.getElementById('buttonId').click() . If the button doesn’t have an id then try to get the button by it’s classname using javascript and perform click() on it.
  3. Now you should see your popup. After the popup closes, you should receive a callback function from payu. Use this callback function to render a success or a cancel view based on the status of the transaction.
  4. Done

Let me know if it is clear or if you need ant further clarification. Kudos!

    Aditya Singh

    Written by

    Javascript develover | Coffee | 420 | Beer