How to put data from DB (Read Data) into email

Include database data in a ChronoForms email without displaying it on the form.

Overview

The issue occurs when using a Read Data action to fetch information for an email, as the data placeholder is not directly available in the email action.
Add a DB Read action within the On Submit event of the form to retrieve the data, making it accessible for use in the email template.

Answered
ChronoForms v6
he hekla 21 Aug, 2019
Hi there

I use Read Data to get the data for a form, which is sent as an email after submitting it by visitor.

For example:
I get some data from the DB field extra_info with Read Data and {var:read_data3.title.extra_info}
I could display the data in form on the web page in a (hidden) field named extra_info and then use {data:extra_info} in the email.

BUT I do not want this data being displayed on the page – I just want it in the email.

My question:
How can I put the data in the email, without having to display it in the form on the web page?
{var:read_data3.title.extra_info} doesn't work …
Gr GreyHead 22 Aug, 2019
Answer
Hi hekla,

You can add it to the User Session data in the On Load event and then re-access it in the ON Submit event; or you can use a DB Read action in the On Submit event and get the data there.

Bob
he hekla 22 Aug, 2019
Thank you, it works (I took the DB Read action in the On Submit event and get the data there)
This topic is locked and no more replies can be posted.