How to display a popup referral page when the embedded signup form is submitted

If you are using the Prefinery embedded form, in its default setting (for a new project) it will automatically be replaced with the referral status widget on submit. But, what if you want to use the embedded form and show the referral status widget in a popup after submit? You can accomplish this by utilizing our form scripts feature

The following example script will redirect the user to the same page or any other page on your website where the Prefinery JavaScript Snippet is installed at and display the referral status widget in a modal dialog (aka popup).

<script>top.location = "https://example.com/signup/?ref-check=" + prefinery_data.user.id;</script>

Just make sure to replace https://example.com/signup/ with the correct URL for the page on your website. The script goes in your form via  Signup Form > JS > Conversion Tracking Code.
chrome_2022-06-07_06-09-53.png

You'll then go to Settings and set the form submit action to either show a thank you message or in its place replace the form with the referral status widget. Don't set it to either redirect option as the popup referral widget wouldn't work. 

Alternatively, perhaps you want to redirect the user to another page where the referral page is embedded at, and not as a popup? If so you can follow along our guide here on how to: Embed the Viral Referral Page on my Site

Still need help? How can we help? How can we help?