Access form data in Form Confirmation Dialog?


#1

Is there a simple way to access the data from a form in the Form Confirmation Dialog?

From what I can tell, I can’t append the form data as URL parameters for the iframe src when using the Form Confirmation Dialog. I also don’t see any form data in the global window.ub object after submitting.

Use case: I’d like to send some custom events via JS from within the Form Confirmation Dialog, and need email address, etc, to make it possible.

Apologies if this is redundant - I searched and found related topics, but nothing specifically about this.

Edited to add: I found an unanswered post from 2011 asking this same question, so confidence in this being possible is low: How to access form field data from a thank you page script?


#2

Just spitballing here… but could you not get the values of the form inputs on change and append them to the href attribute as Get variables?


#3

Hi @TimothyDO - thanks for the suggestion, I mostly follow what you’re saying. The issue is - when using Unbounce’s built in Form Confirmation Dialog, the submit button is just triggering some behind-the-scenes JavaScript to open the modal, so it’s tricky to pass through form data upon submit. If I was sending users to a second URL with a full page refresh, I could just use Unbounce’s “append form data as URL parameters” option, but I’m hoping to be able to accomplish this from within the Form Confirmation Dialog.


#4

Hi there,

You can use dynamic keyword insertion to display data from your form on your confirmation popup.

Here is a link with an explanation and a short video tutorial.

Best,
Hristian