# Fields that are filled in a form and sent to me by email

**URL:** https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204
**Category:** Product Support
**Created:** [June 1, 2023, 1:02pm UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204 "2023-06-01T13:02:11Z")
**Posts on this page:** 19
**Page:** 1

<div class="post-metadata">

### Author: ![diegoom](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/diegoom/32/9771_2.png) [@diegoom](https://forum.mautic.org/u/diegoom)
#### Post date: [June 1, 2023, 1:02pm UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/1 "2023-06-01T13:02:11Z")

</div>

I want that when a user fills out a form, in addition to adding me as a contact (that already does it for me), in what way can I send the data that the contact writes to my email.

I have tried to put in the actions of the form that it sends me an email and it arrives perfectly with the email that I have predefined for it, but I would like an email with the fields that the contact has filled in to also arrive in the same email.

I have seen that it can be put with braces {}, but I don’t know where to look for the exact field name and if they are custom fields, I suppose they can also be looked at somewhere.

you tell me  
Thank you.

---

<div class="post-metadata">

### Author: ![joeyk](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/joeyk/32/11164_2.png) [@joeyk](https://forum.mautic.org/u/joeyk)
#### Post date: [June 1, 2023, 10:24pm UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/2 "2023-06-01T22:24:17Z")

</div>

Did u mean this?

> **[Variables | Mautic](https://docs.mautic.org/en/setup/variables)**
>
> . . Contact fields. Company Contact fields. Mautic Component tokens. Email specific tokens. Landing Page tokens. . Preference Center Landing Page tokens. . Dynamic Web Content tokens. Contact Monitoring. Search filters. Alphabetical list. . . ProTip....

---

<div class="post-metadata">

### Author: ![diegoom](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/diegoom/32/9771_2.png) [@diegoom](https://forum.mautic.org/u/diegoom)
#### Post date: [June 2, 2023, 6:32am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/3 "2023-06-02T06:32:23Z")

</div>

Hello Joeyk, a pleasure.  
Well I have already seen this, but maybe I have not explained myself correctly.  
Imagine I have a Form (in Mautic) where I have 2 custom fields (“mycustomname01”, “mycustomname02”).

In Mautic in the Form, I have told him the following:

- The first thing is that it puts the Contact information in Mautic (this is perfect)
- Then I have told him an Action: Send email  
----- This is where I have the problem:  
----- The email does arrive correctly, but I have set the fields:  
---------- Custom field 01 is: {mycustomname01}  
---------- Custom field 02 is: {mycustomname02}  
----- I can’t capture the data of these fields, because in addition to including it in Mautic, I need the content of those fields that the Contact has filled in to reach me by email.  
I don’t know what I could be doing wrong and I hope you throw me some certainty.

Thanks, as always.

---

<div class="post-metadata">

### Author: ![joeyk](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/joeyk/32/11164_2.png) [@joeyk](https://forum.mautic.org/u/joeyk)
#### Post date: [June 2, 2023, 6:53am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/4 "2023-06-02T06:53:46Z")

</div>

Are you saving the field value in Mautic?

---

<div class="post-metadata">

### Author: ![diegoom](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/diegoom/32/9771_2.png) [@diegoom](https://forum.mautic.org/u/diegoom)
#### Post date: [June 2, 2023, 7:16am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/5 "2023-06-02T07:16:40Z")

</div>

Yes. As custom field.

---

<div class="post-metadata">

### Author: ![joeyk](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/joeyk/32/11164_2.png) [@joeyk](https://forum.mautic.org/u/joeyk)
#### Post date: [June 2, 2023, 8:27am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/6 "2023-06-02T08:27:18Z")

</div>

You can display the field value as {contactfield=alias} Where the alias is the one of the custom field (visible in the custom field page)

---

<div class="post-metadata">

### Author: ![diegoom](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/diegoom/32/9771_2.png) [@diegoom](https://forum.mautic.org/u/diegoom)
#### Post date: [June 2, 2023, 8:44am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/7 "2023-06-02T08:44:28Z")

</div>

This is what I’ve tried, but it didn’t work.  
In the email that arrives I get as if I did not take said field.

---

<div class="post-metadata">

### Author: ![joeyk](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/joeyk/32/11164_2.png) [@joeyk](https://forum.mautic.org/u/joeyk)
#### Post date: [June 2, 2023, 10:07am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/8 "2023-06-02T10:07:39Z")

</div>

Can you check if that field is populated for the contact in question after form submission?  
Also: can you check plz if there is no typo in the token? Also no HTML tags in between when you check the html view?

---

<div class="post-metadata">

### Author: ![dirk\_s](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/dirk_s/32/748_2.png) [@dirk\_s](https://forum.mautic.org/u/dirk_s)
#### Post date: [June 2, 2023, 10:18am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/9 "2023-06-02T10:18:51Z")

</div>

Could you please try, if it works with “standard” fields related to the contact? Currently also the company fields are broken. Maybe there is an issue with custom fields too?

---

<div class="post-metadata">

### Author: ![diegoom](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/diegoom/32/9771_2.png) [@diegoom](https://forum.mautic.org/u/diegoom)
#### Post date: [June 2, 2023, 10:24am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/10 "2023-06-02T10:24:28Z")

</div>

Yes, I have verified it and I am placing the alias. I understand that this is the one I have to put, right?

Anyway it is correct.

---

<div class="post-metadata">

### Author: ![diegoom](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/diegoom/32/9771_2.png) [@diegoom](https://forum.mautic.org/u/diegoom)
#### Post date: [June 2, 2023, 10:33am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/11 "2023-06-02T10:33:03Z")

</div>

Nor does a regular field arrive because I also have the Email field, which is a normal field that Mautic brings.

---

<div class="post-metadata">

### Author: ![joeyk](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/joeyk/32/11164_2.png) [@joeyk](https://forum.mautic.org/u/joeyk)
#### Post date: [June 2, 2023, 10:44am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/12 "2023-06-02T10:44:32Z")

</div>

This is the fix btw:

> <https://github.com/mautic/mautic/pull/11711>
>
> \<!-- ## Which branch should I use for my PR?
> 
> Assuming that:
> 
> a = current ma…jor release
> b = current minor release
> c = future major release
> 
> \* a.x for any features and enhancements (e.g. 5.x)
> \* a.b for any bug fixes (e.g. 4.4, 5.1)
> \* c.x for any features, enhancements or bug fixes with backward compatibility breaking changes (e.g. 5.x) --\>
> 
> | Q | A
> | -------------------------------------- | ---
> | Bug fix? (use the a.b branch) | ✅
> | New feature/enhancement? (use the a.x branch) | ❌
> | Deprecations? | ❌
> | BC breaks? (use the c.x branch) | ❌
> | Automated tests included? | ✅ 
> | Related user documentation PR URL | mautic/mautic-documentation#... 
> | Related developer documentation PR URL | mautic/developer-documentation#... 
> | Issue(s) addressed | Fixes #... 
> 
> \<!--
> Additionally (see https://contribute.mautic.org/contributing-to-mautic/developer/code/pull-requests#work-on-your-pull-request):
> - Always add tests and ensure they pass.
> - Bug fixes must be submitted against the lowest maintained branch where they apply
> (lowest branches are regularly merged to upper ones so they get the fixes too.)
> - Features and deprecations must be submitted against the "4.x" branch.
> \--\>
> 
> \#### Description:
> 
> \<!--
> Please write a short README for your feature/bugfix. This will help people understand your PR and what it aims to do. If you are fixing a bug and if there is no linked issue already, please provide steps to reproduce the issue here.
> \--\>
> 
> \#### Steps to test this PR:
> 
> \<!--
> This part is really important. If you want your PR to be merged, take the time to write very clear, annotated and step by step test instructions. Do not assume any previous knowledge - testers may not be developers.
> \--\>
> 1. Open this PR on Gitpod or pull down for testing locally (see docs on testing PRs \[here\](https://contribute.mautic.org/contributing-to-mautic/tester))
> 2. Create company Test1 with address 1 as Test1
> 3. Create contact and assign company Test1
> 4. Create company Test2 with address 1 as Test2
> 5. Then assign company Test2 to contact as primary but let also Test1 as secondary company
> 6. Create email with tokens like below:
> \`\`\`
> {contactfield=email}
> {contactfield=companyname}
> {contactfield=companyaddress1}
> \`\`\`
> 7. Send template email via campaign or segment email to the contact created above
> 8. Observe the company name and address in the email, it should be Test2
> 
> \<!--
> If you have any deprecations, list them here along with the new alternative.
> If you have any backwards compatibility breaks, list them here.
> \--\>

---

<div class="post-metadata">

### Author: ![joeyk](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/joeyk/32/11164_2.png) [@joeyk](https://forum.mautic.org/u/joeyk)
#### Post date: [June 2, 2023, 10:45am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/13 "2023-06-02T10:45:00Z")

</div>

> [@joeyk](#):
>
> Can you check if that field is populated for the contact in question after form submission?

Can you check if that field is populated for the contact in question after form submission?

Meaning: you open the contact, and you see the value. I’m not talking about form results.

---

<div class="post-metadata">

### Author: ![diegoom](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/diegoom/32/9771_2.png) [@diegoom](https://forum.mautic.org/u/diegoom)
#### Post date: [June 2, 2023, 11:04am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/14 "2023-06-02T11:04:39Z")

</div>

Yes, the data is all correct within the contact file.  
Sending it sends them successfully.

---

<div class="post-metadata">

### Author: ![joeyk](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/joeyk/32/11164_2.png) [@joeyk](https://forum.mautic.org/u/joeyk)
#### Post date: [June 2, 2023, 11:49am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/15 "2023-06-02T11:49:52Z")

</div>

Plz share Mautic version.

---

<div class="post-metadata">

### Author: ![diegoom](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/diegoom/32/9771_2.png) [@diegoom](https://forum.mautic.org/u/diegoom)
#### Post date: [June 2, 2023, 11:51am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/16 "2023-06-02T11:51:37Z")

</div>

The version is this: v4.4.8

---

<div class="post-metadata">

### Author: ![joeyk](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/joeyk/32/11164_2.png) [@joeyk](https://forum.mautic.org/u/joeyk)
#### Post date: [June 3, 2023, 9:35am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/17 "2023-06-03T09:35:08Z")

</div>

> [@diegoom](#):
>
> Sending it sends them successfully.

Sorry, I totally lost the track here.

1. The form is saving the values in the custom field
2. The form has an action ''Send email to user" does not send the proper {contactfield=contactalias} feid value, but remains empty.  
Correct?

---

<div class="post-metadata">

### Author: ![diegoom](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/diegoom/32/9771_2.png) [@diegoom](https://forum.mautic.org/u/diegoom)
#### Post date: [June 5, 2023, 12:13pm UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/18 "2023-06-05T12:13:19Z")

</div>

Hello, everything you asked me was correct until I tried it again today.  
It looks like this will be updated with the Crons and I would try to do it before they were running to update this information. That day he did not send me anything, he placed the field with the keys without the information.

Today he already sends me that information correctly and without doing anything on my part.  
That’s why I guess it would be the Cron. I didn’t leave a minimum update time I guess.

Thank you.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex020/uploads/mautic/original/1X/43c63600fe51440378769136903f1fa2a9a34102.png) [@system](https://forum.mautic.org/u/system)
#### Post date: [June 7, 2023, 12:14am UTC](https://forum.mautic.org/t/fields-that-are-filled-in-a-form-and-sent-to-me-by-email/28204/19 "2023-06-07T00:14:03Z")

</div>

This topic was automatically closed 36 hours after the last reply. New replies are no longer allowed.
