Attach form data as a CSV file
Note: These features are part of the Visforms Subscription and are not included in the free Visforms version.
For a better understanding, we recommend reading the documentation completely and using the
Section Introduction
to start.
Relationships explained in earlier sections of the documentation are not repeated here.
Save result must be activated
In addition to any file attachments and PDFs of the form data and emails, the plugin also offers you the following option. You can export the submitted form data to a CSV file and send this file with the result mail.
In order to be able to use this feature, the “Save result” option must be activated in the form configuration under the “Result” tab. Otherwise, the data will not be saved and therefore cannot be exported.
Please do not confuse this feature with the actual data export. The actual data export can be found in the administration in the data view. With the actual data export, you can create a CSV file of the form data and save it on your local machine. When data is exported using the “Email attachments” plugin, a CSV file is only created temporarily on the server when the form is sent. This temporary file is deleted immediately after the mails have been sent.
Safety first
When configuring the CSV attachment options, please note that the submitted form data may contain sensitive user data. Please make sure that exported data is only emailed to people who are allowed to see it. In order to make the handling of the stored data as safe as possible, we have developed the plugin in a special way. The CSV attachment options in the administration are only visible to super admins and can therefore only be changed by super admins.
Note:
Protecting submitted form data from unintentional disclosure is also the reason for the following.
It is not possible to attach the CSV file to the user mail.
CSV attachment options
The plugin gives you the option to turn on or off the creation of a CSV attachment. There is also a whole range of options to flexibly control how the CSV file should look like. If you have already used the Visforms data export functionality from the administration, you will see that these are very similar to the CSV attachment options. Because you have already made settings for this in the configuration under the “Advanced” tab.
So you have a complete set of export options for each type of data export. The plugin only uses the options that you set under the two tabs “Email attachments” and “Edit email attachments”.
In the case of an unfavorable combination of options, no CSV file is created and no attachment is sent
Please note that an unfavorable combination of export options can result in no data being exported. The plugin only generates the CSV file if it is not empty. In this case, no CSV file is created. As a result, there is no attachment in the mail.
For example, if you set the following simultaneously:
- In the form configuration under the tab “Data display in the frontend” the option “Publish data automatically” is set to “no”.
- At the same time, the two options “Only published records” and “Only this record” are set to “yes” in the CSV attachment options.
Just the current record or all?
On the one hand, the configuration options are designed so that you can export all data that has already been transmitted, including the current transmission. So the CSV file gets a bit longer with each form submission, and you always get a complete list automatically.
On the other hand, you can also export only the currently transmitted data record. An overview of all transmissions is then obtained from the sum of all CSV files that were sent with all result emails for the respective form. Such one-data-set CSVs could, for example, be used for automated further processing in third-party systems.
This is additionally supported by the following. It is also possible to turn on or off a first row containing the field names as column headers. This is done using the “Export Header” option.
Meta information about the records
Furthermore, there is a whole range of options regarding the so-called meta information of the data records. Meta information is automatically saved for each data set by Visforms. You can individually include or exclude this meta information in the export.