Contact Form 7 - show Popup after submit

CF7 offers some JavaScript events that we can hook into. Using those events, we can create a small snippet to open a Popup after a successful contact form submission:

<script>(function($) {
  DiviArea.addAction('ready', function() {
    $('.wpcf7').on('wpcf7submit', function (event) {
    	// Status "mail_sent" means, that the form submit is complete.
    	if ('mail_sent' === event.detail.status) {'#after-submit'); // ← Change this to your Popup ID.

→ Open in the Script Generator

Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.