How to use Iframe Embed widget for different forms of payment

  • Profile Image
    Asked on February 26, 2016 at 08:13 PM

    I´m doing tests as how to use 2 different forms of payment (stripe and paypal) in one form using the iframe embed widget. I have done the main form:

    And I have done the 2 other forms for paypal and stripe, but I have some questions

    - Do I need 2 iframe widgets? or can I have one form of payment in the original form, for exambple paypal, and have the stripe form in the embeded form? I this case, guess I would have to hide paypal for stripe to work?

    - Which submit button should I leave? Right now if you choose paypal or credit card you can see 2 submit buttons

    - Is there a way to prepopulate fields on the embed forms? I am using the custom field to get the amount to pay and I would like to have that field prepopulated, and maybe even another field like the email (assuming the information from the embeded form will only be filled seperately and will need a field to identify and match with the original form...?)

  • Profile Image
    Answered on February 27, 2016 at 04:02 AM

    We highly recommend that you have three forms, so that you can ask all form questions on each of the two payment forms. Here is the guide that explains the process:

    Essentially, your main form that will act as the container will not have any submit button, nor any other questions except which payment tool to use. Once a selection is made, an entire payment form with all the questions and that selected payment tool will load inside the iFrame widget.

    Please take a look at the above linked guide for more details. In order to set up a multiple payment form, you will be doing the same as in the above guide, with only change of using Stripe instead of the Purchase Order tool.

    Please let us know if you need further assistance, we'll be happy to help.

  • Profile Image
    Answered on February 27, 2016 at 05:03 AM

    thankyou, but... when you go to a store to buy something, you first pick the product, then decide your form of payment... so not sure that will work...

    I´m not a programmer, so, technicaly speaking, I would like to check if what I have done is correct.

    In my main form I have the paypal option included, but if they choose credit/debit card and submit, they will be redirected to another form (using the thankyou url redirection) and in that second form I have prepopulate some fields and have the stripe form of payment.

    technicaly speaking, is there any problem with this?

  • Profile Image
    Answered on February 27, 2016 at 07:18 AM

    Your alternative method sounds good as well, it can work that way as well.

    In your first form, you will have to use (1) a show condition to show the PayPal field only when Paypal is selected. This will ensure that PayPal will be hidden when other options are selected, and the form will not redirect users to PayPal in that case.

    Then, you will also have to use (2) a "Change thank you page" condition to redirect users to your Stripe form when Stripe/credit card is selected.

    In the URL you use for redirecting to the second form, you can simply populate fields of the second form by using URL parameters:

    That should work as well, and if you run into any issues while setting it up, we are always here to help. :)