Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter Bondra

    (@bondra)

    No submission are being tracked by Google Analytis… yet. But I’m not too sure if I can have two rows like the one I mentioned above?

    Hey Bondra! You can try something like this:

    on_sent_ok: "onSentOkFunc();"
    function onSentOkFunc() {
    	_gaq.push(['_trackEvent', 'Contact Form', 'Submit']);
    	window.location = "https://www.yoururl.com";
    }

    You define custom function onSentOkFunc() and call as many functions as you want inside that and call it on send event.

    Can someone verify if this works?

    Actually with one of the latest updates of CF7 it is now possible to set multiple events on send event. Wrapping function is not necessary. Just like this:

    on_sent_ok: "_gaq.push(['_trackEvent', 'Contact Form', 'Submit']);"
    on_sent_ok: "location = 'https://example.com/';"

    Dmitry,

    I have 2 submit buttons on the form. Can I have 2 on_sent_ok in the Additional Settings
    example
    on_sent_ok: ” if (document.getElementById(‘chessrating’).value> 2200) {location.replace(‘https://www.greensborochess.org/thank-you-for-your-participation’)} else …….;}”

    on_sent_ok: “location = ‘https://example.com/’;”

    Please advice
    Thanks
    Jacob

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Add multiple on_sent_ok?’ is closed to new replies.