Skip to content

Instantly share code, notes, and snippets.

@henkisdabro
Last active January 22, 2021 04:16
Show Gist options
  • Save henkisdabro/cf9ada69e89469be64c9c73e13d3fe64 to your computer and use it in GitHub Desktop.
Save henkisdabro/cf9ada69e89469be64c9c73e13d3fe64 to your computer and use it in GitHub Desktop.
Execute this dataLayer.push on successful validated form submission
<script>
// to be executed on successful validated form submission of form id: #formWaitingList located on page path: /waitinglist.php
window.dataLayer = window.dataLayer || [];
window.dataLayer.push({
'event': 'waiting list form submission'
});
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment