/Contact-Form-7-CSV-Attachment

Attach the contents of a form submission to a .csv file powered by the popular WordPress contact form 7 plugin

Primary LanguagePHPMIT LicenseMIT

Include Contents of CF7 to CSV mail attachment

A short but useful function to store mail contents of a CF7 submission to a CSV file and clear the file after successful submission - got to keep GDPR happy...

Usage

Add the code to your functions.php file and adjust accordingly. You'll need to add your form ID, field names and CSV path (within uploads).

The code is commented fully but as mentioned your CSV file needs to be saved within wp-content/uploads to play nice with CF7 security.

License

MIT