Skip to content

Instantly share code, notes, and snippets.

@johnnyopao
Last active December 15, 2022 11:41
Show Gist options
  • Save johnnyopao/54790aef1f81eb68a03a to your computer and use it in GitHub Desktop.
Save johnnyopao/54790aef1f81eb68a03a to your computer and use it in GitHub Desktop.
Close your Unbounce Form Confirmation Dialog lightbox with a button

Set the buttons URL to

javascript:lp.jQuery.ubpoverlay.close()
@samthomson
Copy link

sadly this no longer works, any ideas for a replacement?

@johnnyopao
Copy link
Author

Hey Sam - I'm not sure. If this no longer works, then Unbounce might have changed something with the overlay code.

I used to work there and would provide this to customers. I'm not sure what the new option might be so I'd reach out to the Unbounce support team for alternatives. I'm sure they'll be able to help!

@samthomson
Copy link

Hi, thanks for that.
In the end I 'solved' it with top.lp.jQuery('button[type=button][role=button]').click() - a bit hacky but it gets the job done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment