How to pass URL parameters to a form

I wanted to know how to send a link in an email from Mautic to a contact. That link is to a form on a landing page, and I wanted that form to already have the person’s email address pre populated so they will not have to fill it in. There are instructions in the docs but they are more complicated than they need to be.

Here is what you do.

  1. Create the form make sure to add the email field. This can be a hidden field but I used a visible field so I could see if it was pre populating right in the form.
  2. Set the email behaviour to auto fill and show if it exists.
  3. Finish setting up your form
  4. Go to the gear icon top right and open custom fields.
  5. Look for the email field and click on it.
  6. Flick the switch to make the email field publicly editable.
  7. Create a landing page and add the form you have created.
  8. Create the email that conatins the link to the landing page that holds the form.
  9. When creating the link you need to add https://url of the landing page with the form?email={leadfield=email|true}
  10. The ?email={leadfield=email|true} is the key and must be addend to the end of the landing page url. No space, no / between the end of the url and the ?
  11. test in incognito mode while completely logged out of mautic.

This worked for me. In theory you could pass any mautic field using the same logic and just changing the lead filed or contact filed in question.

Hope it helps someone else.

This has been a guide for idiots like me.

3 Likes