• Resolved gianlucaweb

    (@gianlucaweb)


    Hi, i added the following code at the bottom of the functions.php file:

    add_action( ‘wp_footer’, ‘mycustom_wp_footer’ );
    function mycustom_wp_footer() {
    ?>
    <script type=”text/javascript”>
    document.addEventListener( ‘wpcf7mailsent’, function( event ) {
    if ( ‘123’ == event.detail.contactFormId ) {
    ga( ‘send’, ‘event’, ‘Contact Form’, ‘submit’ );
    }
    }, false );
    </script>
    <?php
    }

    now i would like to redirect the user to the thank you page after he clicks on “Send” button.

    Have i to add

    on_sent_ok: “location = ‘http://www.domani.com/thankyoupage/&#8217;;”

    in the Additional Settings tab?

    Thak you so much

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘DOM Events’ is closed to new replies.