Migration from Pardot - form handlers | Community
Skip to main content
New Participant
April 27, 2020
Question

Migration from Pardot - form handlers

  • April 27, 2020
  • 1 reply
  • 3826 views

Hi,

We're moving away from Pardot to Marketo. We currently have forms on the website using Pardot's form handlers. Preference is that we want to keep the website forms and use something that we can post the info from the forms to Marketo.

I've been reading and searching for information about is there any equivalent to that in Marketo, but I'm failing to find.

Am I missing something? I've always been using the embedded forms until now and this is unfamiliar territory.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

1 reply

SanfordWhiteman
New Participant
April 27, 2020

There's not just 1 but 2 different ways to post data from a 3rd-party form to a Marketo forms endpoint.

 

The more "packaged" way is to pass the data to a hidden Marketo Forms 2.0 form and call the JS API's submit() method. You grab the field values from your form, assemble them as a JS object (which will likely involve mapping the Pardot field names to Marketo names, or maybe not if they happen to be aligned!).

 

The more primitive way is to post to the Marketo scriptless endpoint, which is pages.example.com/index.php/leadCapture/save (where pages.example.com is your Marketo LP domain). This is a standard (x-www-form-urlencoded) form post, nothing special at all. You can see how this works easily by setting up a Marketo LP. The <noscript> version of the form posts to that same endpoint.

PavelIv1Author
New Participant
April 28, 2020

Thank you, Sanford!

I think I'm doing something wrong, because I don't get any results.

 

<script src="//xxxxxxxxxx.marketo.com/js/forms2/js/forms2.min.js"></script>
<form id="mktoForm_1217" style="display:none"></form>
<script>
MktoForms2.loadForm("//xxxxxxxxxx.marketo.com", "xxxxxxxxxx", 1217, function(form){
var myForm = MktoForms2.allForms()[0];
myForm.addHiddenFields({
//These are the values which will be submitted to Marketo
"FirstName":"first-name",
"LastName":"last-name",
"Title":"title",
"Email":"email",
"Phone":"phone",
"Country":"contact-country"
"State":"contact-state",
"customBuyerField1":"comments"
});
myForm.submit();
});
});
</script>
SanfordWhiteman
New Participant
April 28, 2020

Please highlight your code using the Syntax Highlighter, then we'll continue.