Skip Navigation

[Resolved] How to add some attachments in the post form's e-mail notification?

This support ticket is created 4 years, 10 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Hong_Kong (GMT+08:00)

This topic contains 3 replies, has 2 voices.

Last updated by Luo Yang 4 years, 10 months ago.

Assisted by: Luo Yang.

Author
Posts
#1271147

Tell us what you are trying to do?

Hello,
I would like to add some attachments to post form's email notification. I need to send the files, not just making the links in the notification's text (body).

Is there any other solution (making some connection with some other e-mail platform.... Mailchimp etc.)?

Many thanks for your suggestion, best.

Jiri

#1271215

Dear Jiri,

There isn't such a built-in feature within Toolset Forms plugin, see the source codes of plugin file cred-frontend-editor\library\toolset\cred\embedded\classes\common\Mail_Handler.php, line 207:

$isSend = wp_mail($to, $subject, $body, $header);

There isn't $attachments parameter in above codes
https://developer.wordpress.org/reference/functions/wp_mail/

So you might consider custom codes, for example, use WordPress built-in filter hook wp_mail to trigger a custom PHP function, in this function add attachments to the emails, see WordPress document:
https://developer.wordpress.org/reference/hooks/wp_mail/

#1277915

Dear Luo,
thanks for your answer, could you please give me at least some example of this solution? I am not able to do it from scratch.

Thank you, best,
Jiri.

#1277995

According to our support policy, we don't provide custom codes support:
https://toolset.com/toolset-support-policy/

In below WordPress document, there is an PHP codes example:
https://codex.wordpress.org/Plugin_API/Filter_Reference/wp_mail

For your reference.

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.