Skip to main content
Known Participant
February 16, 2010
Question

failto attribute of <cfmail tag

  • February 16, 2010
  • 4 replies
  • 3824 views

The failto attribute of the cfmail tag doesn't seem to be working the way I expect it to.  Consider this snippet of code:

   <cfmail from="me@mydomain.com"

              username= "me@mydomain.com"
              password= "MyPassword"

              to=   "Test@mydomain.com"

              subject= "Test"
              failto=  "me@mydomain.com">   

Assume me@mydomain.com is a valid email addres, and Test@mydomain.com is not.  When executing this, I do see the mail in the undeliverable folder, but I would expect to receive some type of notice at me@mydomain.com indicating that transmission failed.  I do not.

Am I doing something wrong?

This topic has been closed for replies.

4 replies

Inspiring
February 24, 2010

The failto: (known as return-path) only allows one address as the property is setting the address of the originator of the e-mail, not for reporting purposes. If you need multiple recipients, set up an e-mail group; even though this is not the correct use, it could be used for that.

4.3.1. RETURN-PATH

This field is added by the final transport system that

delivers the message to its recipient. The field is intended

to contain definitive information about the address and route

back to the message’s originator.

Note: The “Reply-To” field is added by the originator and

serves to direct replies, whereas the “Return-Path”

field is used to identify a path back to the originator.

While the syntax indicates that a route specification is

optional, every attempt should be made to provide that information in this field.

Taken from:

http://www.w3.org/Protocols/rfc822/

Inspiring
February 17, 2010

Do you have correct mail settings in the CF Administrator?  Maybe CF is trying to use those credentials to send failure email.

Inspiring
February 16, 2010

Check your mail log and see why it is in the Undeliverable folder.  There might be something wrong with the email that prevented an attempt to send it.

BKBK is partially correct, I think.  My obervations are that if the recipient's mail server can't find the email address, you get a delivery failure notification and nothing goes to your undeliverable folder.  However, if the mail is rejected as spam, the opposite occurs.

Also, delivery failure notifications are not always instant.

BKBK
Community Expert
Community Expert
February 16, 2010

I think failto will work if only the intended recipient's mail server sends back a mail delivery failure notification. 

Inspiring
February 16, 2010

Somewhat interesting is that there's no mention of failto support in the SMTP RFC (http://www.ietf.org/rfc/rfc2821.txt), and most of the matches on Google for failto (well: 'failto -"failed to" - "fail to"') match threads about <cfmail>.

I wonder whether CF has some false expectations as to how SMTP servers work?

Or (more likely) whether I'm misunderstanding something...?

--

Adam