Created
March 15, 2018 16:52
-
-
Save RitwikGA/5faa87946a16afc24ddf8e358c2403a6 to your computer and use it in GitHub Desktop.
Contact Form 7 Tracking in GTM
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
document.addEventListener( 'wpcf7submit', function( event ) { | |
if(!isTrusted) | |
{dataLayer.push({'event':'formSubmit','formId':event.detail.contactFormId})} | |
}, false ); | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment