Skip to main content
Participating Frequently
March 25, 2022
Answered

CFMAIL does not deliver to recipients in CC List

  • March 25, 2022
  • 1 reply
  • 1073 views

I simply cannot get the CC part of the code below to work. The message is delivered to three recipients, but not delivered to the CC recipient.

 

<cfquery name="GetTOEmails" datasource="PURCH">
          SELECT ApproverEmail
          FROM [PurchaseRequisitions].[dbo].[Approvers]
          WHERE TierLevel='01'
</cfquery>

 

<cfmail
          query="GetTOEmails"
          from="My Domain User <mydomainuser@domain.com>"
          to="#GetTOEmails.ApproverEmail#"
          cc="another@domain.com"
          subject="Another Test"
          server="myserver"
          username="myuser"
          password="mypassword"
          priority="highest"
          port="25"
          type="html">

 

          <span>Test from A1</span>

 

</cfmail>

Sent from A1

This topic has been closed for replies.
Correct answer BKBK


I am only in the CC list, not in the TO list.

  • User A (in the TO list) gets the email and I am visible in the CC field on the actual email.
  • User B (in the TO list) gets the email and I am visible in the CC field on the actual email.

 

I just never get the email. BCC also doesnt seem to work, and I am following the Adobe examples, so I have no idea really.

 

By @Jack237508762pcn

 

Since you know that mail is successfully sent to User A and User B, you should do the following test:

 

  • Construct a new TO-list as follows: it should exclude the e-mail addresses of User A and User B, but include the e-mail address that currently fails as CC.
  • Use User A's address as CC and User B's address as BCC.
  • Run cfmail with those settings.

 

Does everyone receive mail?


Hi @Jack237508762pcn , any update on this?

1 reply

George____
Inspiring
March 25, 2022

If you stop the spooler you can look at the cfmail file that gets produced and verify it looks correct.   It might be a typo.   Another possibility is something external to the CF server is blocking the email, especially if you're sending to another domain.

 

You might also want to have the another@domain.com receipt double check that it's not going to their junk folder and that they don't have any rules setup to automatically move your test messages.   I ran into that before where the user claimed they weren't getting any emails and it turned out they had created an Outlook rule and forgot about it.

 

Participating Frequently
March 25, 2022

Appreciate you responding George - thank you.


I am trying to CC myself in this example and I can see on the email (from the To list of people) that I am copied in and correctly, but I just never get the email.

 

 

 

 

George____
Inspiring
March 25, 2022

If you're saying you're also on the TO line you won't get two emails, you'll only get one.   I think the email servers will also remove you from the CC line in that case.   Basically you can't be in two places at once.