Last active
May 30, 2024 13:04
-
-
Save techjewel/97436ac512ff9607d1ebb64af33f0d31 to your computer and use it in GitHub Desktop.
Form submission success JS Event in Fluent Forms
This file contains 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
// Event on form submission success | |
// You can paste this script to Form's custom JS Box | |
$form.on('fluentform_submission_success', function() { | |
// You can run your own JS and will be run on successful form submission | |
}); |
This code snippet is a JavaScript function designed to execute specific actions upon the successful submission of a form. It uses jQuery to isten for the form submission event and integrates Facebook Pixel for tracking purposes. Here’s a breakdown of each part of the code:
$form.on('fluentform_submission_success', function() {
fbq('track', 'Lead');
console.log('form tracked');
});
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thank you