SOLVED

Re: Prefil email field using url parameter

Go to solution
Ed_Wong
Level 2

Re: Prefil email field using url parameter

Nice! Got it to work. Thank you, again!

For others, i added a new Rich Text field in the form containing nothing but <span id="showEmail"></span>

save & approved the form

re-save & approved landing page

Lucho_Soto
Level 5

Re: Prefil email field using url parameter

Will an email token work if used as the default value? We're also looking at an example where most traffic won't have parameters but we want to keep the email field hidden.

I wasn't able to get this to work on an external landing page, but am wondering if this would work on a Marketo landing page.

SanfordWhiteman
Level 10 - Community Moderator

Re: Prefil email field using url parameter

Not sure exactly what you're asking...

  • A {{lead.token}} can't be used on an non-Marketo LP.
  • On a Marketo-hosted LP, if you want the Email Address field to be hidden, just set the type to Hidden, enable Pre-Fill, and also enable Auto-Fill from a URL param with the default value {{lead.Email Address}}. The URL param will take precedence, if non-empty (i.e. an empty but present URL param, like ?email=&utm_campaign=blah... will not set the value to empty but will use the existing lead value).
Neil_Robertson6
Level 5

Re: Prefil email field using url parameter

That is the way to do it but I would, if possible, see if you can encrypt/decrypt the string and not pass emails in the URL as plain text - otherwise your database could be open for rogue unsubscribes.

SanfordWhiteman
Level 10 - Community Moderator

Re: Prefil email field using url parameter

Unless you mean leaving it encrypted all the way to the back end (necessitating a custom, very complex back-end workflow that I don't know that anybody is actually doing in reality) then you can already post the form on behalf of whomever you choose.

John_Clark1
Level 10

Re: Prefil email field using url parameter

It's also possible that your CC staff could unsubscribe leads themselves.  You'd just want to be sure that munchkin was removed from the page so their browsers didn't get cookied as the lead's themselves.  You can find instructions for that below.

How to remove Munchkin from landing pages

John

SanfordWhiteman
Level 10 - Community Moderator

Re: Prefil email field using url parameter

You need to remove the _mkto_trk cookie / _mkt_trk field from the form as well, not just remove Munchkin (because staff will already have a Munchin cookie).

Anonymous
Not applicable

Re: Prefil email field using url parameter

Thanks john, but we want to leave it up to the customer to confirm the correct email address to unsubscribe, not the CC staff.