SOLVED

Progressive Profiling/Form Prefill on Embedded form

Go to solution
Anonymous
Not applicable

Re: Progressive Profiling/Form Prefill on Embedded form

Hi Sanford,

So the article linked is incorrect for form pre-fill? http://developers.marketo.com/blog/external-page-prefill/

I am not a developer and trying to get information that I can pass onto our external developer.

Cheers!

SanfordWhiteman
Level 10 - Community Moderator

Re: Progressive Profiling/Form Prefill on Embedded form

Actually, I may have mistaken which post you were tagging. I was actually noting that Robb's comment about the Known Lead HTML + Filled Out Form activities wasn't right.

But no, I don't think any sane person should use the method in that post, for the DoS reasons I described above.

Brad_Perry
Level 1

Re: Progressive Profiling/Form Prefill on Embedded form

Is anybody seeing a 30-40 second delay from when a user first clicks through an email to when the Marketo Cookie is associated to a lead (You can make rest API queries and you'll get empty results until 30-40 seconds have past)?

Brad_Perry
Level 1

Re: Progressive Profiling/Form Prefill on Embedded form

The article is great, but the prefill doesn't work for first time users. Works for repeat though

Like I said, I'm seeing a 30-40 second delay before the REST cookie query will return with a match. Associating a cookie value to a lead is taking Marketo way to long.

I've opened a case. Really if Marketo can provide you with a cookie value you should be able to do a query on it immediately and get results. If not, its just plain poor engineering/systems.

SanfordWhiteman
Level 10 - Community Moderator

Re: Progressive Profiling/Form Prefill on Embedded form

The cookie is generated entirely on the browser, so there's no correspondence between its availability on the client and its association with a named lead (or even its logging of activities to an anonymous lead).

Association is always asynchronous, and 30s latency happens. Merging with existing leads can't be expected to be complete by the next pageview.

Brad_Perry
Level 1

Re: Progressive Profiling/Form Prefill on Embedded form

Ok. I assumed Marketo generated a unique cookie value.

But now I'm curious, If the cookie is generated entirely from the browser, how does Marketo ensure that a cookie value is unique then and won't give false matches in the case that an identical cookie value is assigned to more than one device (Probably fairly unlikely, but possible)?

So here is what I think I'm going to do to enable prepop:

1.) Create a webhook that will preface the Marketo lead ID with a random string. Return this new value in a custom field. Run this each time a new lead is created. This new field will be used as a lookup field (This is necessary. You could use the email as a lookup value, but that will cause privacy/security issues. You could use the marketo lead id, but that would leave you open to security issues, where someone could iterate through IDs quite easily and gain access to customer/lead information.)

2.) Merge this custom field as a parameter in email links

3.) When a user hits a landing page with a form, get the value from the URL. If it exists and do a lookup to get the necessary fields to prefill the form. If the value does not exist in the URL, do a lookup based on the cookie for the necessary fields to prefill the form.

SanfordWhiteman
Level 10 - Community Moderator

Re: Progressive Profiling/Form Prefill on Embedded form

...how does Marketo ensure that a cookie value is unique then and won't give false matches in the case that an identical cookie value is assigned to more than one device?

Analytics libraries always create session cookies client-side. There's no guarantee of crypto-grade uniqueness (i.e. v4 GUID) across browsers in any case, since some browsers only have Math.random(), but Marketo's algo definitely is less than perfect: between the timestamp in milliseconds + random 5-digit suffix it's extremely unlikely, but not impossible, to have a duplicate. You can set your own cookie value if this is a deep concern (add more entropy to the timestamp portion).

1.) Create a webhook that will preface the Marketo lead ID with a random string. Return this new value in a custom field. Run this each time a new lead is created. This new field will be used as a lookup field

OK -- you'd just need to left-pad the Lead ID to a fixed length for this to work, unless you're using only alpha characters.

3.) When a user hits a landing page with a form, get the value from the URL. If it exists and do a lookup to get the necessary fields to prefill the form. If the value does not exist in the URL, do a lookup based on the cookie for the necessary fields to prefill the form.

I would never, ever implement this because of the clear DoS vulnerability. But it'll work up until that point.