Formidable Form Event Listener
How to track Formidable Form Submission with google tag manager
Use Google Tag Manager with this event listener to track Formidable form submissions as conversions in your analytics and advertising platform.
Begin by creating a custom HTML tag in Google Tag Manager, copying the Formidable form event listener code, pasting it in the tag, and attaching a pageview or DOM-ready trigger.
The following step is to create a custom event trigger that only happens on successful form submissions with an event name of [formidable_form_submitted].
Create a dataLayer variable with the designated key [formID] to collect the form ID.
Afterwards, you can effortlessly activate your marketing conversion tags/pixels through the custom event you’ve created for successful Formidable form submissions [formidable_form_submitted].
With the assistance of the form ID variable, you can integrate the form ID into your analytics stack or refine your trigger conditions to optimize your marketing efforts.
<script> jQuery(document).ready(function($){ $(document).on( 'frmFormComplete', function( event, form, response ) { var formID = $(form).find('input[name="form_id"]').val(); window.dataLayer = window.dataLayer || []; window.dataLayer.push({ 'event': 'formidable_form_submitted', 'formID': formID }); });}); </script>