Duh, it returns a boolean... you get the point... -Dov

  _____  

From: Katz, Dov B (IT)
Sent: Wednesday, January 21, 2004 2:57 PM
To: CF-Talk
Subject: (CFMX RFE) RE: CFMX 'bug'? Easy to crash CFMAIL.


Here's my informal CFMX RFE based on this discussion:


1) add a new string function to the cf function library.
    public String isValidEmail(String s){
        try{
            new javax.mail.internet.InternetAddress(s);
            return true;
        }    catch (javax.mail.internet.AddressException e){
        return false;
    }
}


2) Add to the CFMail tag routine a CFQuery object called
"FAILED" with
the same row structure as the original query, if one is passed
in. Put a
copy of each failed row in there.


-Dov

  _____  

From: Christian Cantrell [mailto:[EMAIL PROTECTED]
Sent: Wednesday, January 21, 2004 2:41 PM
To: CF-Talk
Subject: Re: CFMX 'bug'? Easy to crash CFMAIL.


On Wednesday, January 21, 2004, at 10:18  AM, Tyler Clendenin
wrote:

> My main problem with this is that if you send to a query and
it throws
> an
> error it stops mid e-mail and does not rollback or anything it
only
> sends
> out the first percentage of the e-mail before the bad e-mail
address.

Do you mean if you pass a query into the CFMAIL tag?  That's the
price
you pay for convenience.  If you have validated all your email
address
on their way in, use this feature with confidence.  If you have
not,
then loop through the query manually and either validate or
catch
errors.  Sometimes the most convent solution is not the most
appropriate for your needs.

Christian
  _____
  _____
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to