Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

&emailBCC not working and preventing email from sending #291

Open
JSkaggs-Forthea opened this issue Apr 10, 2024 · 1 comment
Open

&emailBCC not working and preventing email from sending #291

JSkaggs-Forthea opened this issue Apr 10, 2024 · 1 comment

Comments

@JSkaggs-Forthea
Copy link

Bug report

Summary

&emailBCC breaks the form report email.

Step to reproduce

Example FormIt call:
[[!FormIt?
&emailTpl=contact-report
&emailTo=[email protected]
&emailBCC=[email protected]
&emailSubject=Contact Form Submission
TRUNCATED FOR SPACE

Observed behavior

When using &emailBCC with either a single or comma-separated list of emails, the report email does not send at all. Neither the &emailTo address nor the &emailBCC address(es) receive the report email. No related errors appear in the MODX Error Log.

When removing &emailBCC, the form report email is received by the &emailTo address.
When changing &emailBCC to &emailCC, the form report email will be sent as expected with the emailCC email(s) set as CC. This is true with a single or comma-separated list of emails.

Expected behavior

The form report email should be received by the &emailTo and &emailBCC addresses.

Environment

NGINX via MODX Cloud / MODX v3.0.4-pl / PHP 8.1 / FormIt v5.0.1-pl

@halftrainedharry
Copy link

I can't reproduce any issues with the &emailBCC property. It works correctly when I test it (using the same versions of MODX/PHP/FormIt).


FormIt uses modMail to send E-Mails. modMail is part of the MODX core code and a wrapper for the PHPMailer library.
Does sending an email with BCC work on your system when you use a custom snippet?
Here is some sample code to send an E-Mail in MODX 3.
Add $mail->address('bcc', '[email protected]'); for the BCC address.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants