filipr27

GA - form - software - inquiry

Jun 2nd, 2022 (edited)
157
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // Fire this dataLayer event when a successful submission of a form occurs. The event should fire only for successful submissions. The event shouldn't fire again if the user reloads or revisits the thank-you page.
  2.  
  3. <script>
  4. window.dataLayer = window.dataLayer || [];
  5. window.dataLayer.push({
  6.  'event': 'form_engagement',
  7.  'formAction': 'Submission',
  8.  'formCategory': 'Contact Sales',
  9.  'formName': 'AI in Delfi',  // Variable value, based on which product/service the form is for.
  10.  'formId': '123',  // Variable value - the ID of the form.
  11.  'formInterest': 'Digital Infrastructure'  // Variable value based on what user selects from the Subject Of Interest dropdown.
  12.  });
  13. </script>
  14.  
  15.  
Advertisement
Add Comment
Please, Sign In to add comment