Skip to content

Commit

Permalink
Build out AJAX submission for Formidable
Browse files Browse the repository at this point in the history
Issue #750
  • Loading branch information
fpcorso committed Aug 20, 2020
1 parent 395c23e commit 191238c
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions assets/js/src/integration/formidableforms.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
/***********************************
* Copyright (c) 2020, Popup Maker
**********************************/

{
const formProvider = "formidableforms";
const $ = window.jQuery;

$(document).ready(() => {
$(document).on("frmFormComplete", function(event, form, response) {
var $form = $(form);
var formId = $form.find('input[name="form_id"]').val();

// All the magic happens here.
window.PUM.integrations.formSubmission($form, {
formProvider,
formId,
extras: {
response
}
});
});
});
}

0 comments on commit 191238c

Please sign in to comment.