Problem validating email addres?? Email is not accepted.

Swift Mailer is a fantastic library for sending email with php. Discuss this library or ask any questions about it here.

Moderators: Chris Corbyn, General Moderators

Post Reply
bruno_mac
Forum Newbie
Posts: 6
Joined: Mon Jan 14, 2008 3:34 pm

Problem validating email addres?? Email is not accepted.

Post by bruno_mac »

Hi,

I have been using Swift Mailer for quite some time and I've been getting this error for some time as well. I never had time to investigate the error so I just end up removing that email from my list to send out the campaign.

I get this error:

Code: Select all

 
Fatal error: Uncaught exception 'Exception' with message 'The recipients parameter must either be a valid string email address, an instance of Swift_RecipientList or an instance of Swift_Address.' in /home/admin/domains/mydomain.com/public_html/app/tools/Swift-3.3.2-php5/lib/Swift.php:337 Stack trace: #0 /home/admin/domains/mydomain.com/public_html/app/daemons/send_welcome.php(183): Swift->send(Object(Swift_Message), 'mwakelin@kingsw...', Object(Swift_Address)) #1 {main} thrown in /home/admin/domains/mydomain.com/public_html/app/tools/Swift-3.3.2-php5/lib/Swift.php on line 337
 
The only difference with this address is that it has a _ 'underscore' in the domain part of the email. Does Swift do any time of check on the format of the email address? I couldn't find anything about this. If the _ is in the first part of the email it works ok.

john_doe@big.com: works ok
john_doe@not_big.com: fails with the exception error above.
johndoe@not_big.com: fails with the exception error above.

Any help would be great.
Thanks,
Bruno.
Isoik
Forum Newbie
Posts: 5
Joined: Tue Oct 28, 2008 1:07 pm

Re: Problem validating email addres?? Email is not accepted.

Post by Isoik »

These:

Code: Select all

john_doe@not_big.com: fails with the exception error above.
johndoe@not_big.com: fails with the exception error above.
Are incorrect E-mails because domain names don't allow the underscore. E-mail IDs on the other hand do.
Post Reply