-
Notifications
You must be signed in to change notification settings - Fork 157
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
Loop stop #21
Comments
Hi, It's hard to say exactly without the specific line number in the unhandled exception error (if you're running the latest 'master' version at all). As the comment here says: https://github.com/zytzagoo/smtp-validate-email/blob/master/smtp-validate-email.php#L704
From the debug output it seems you didn't even get to the HELO/EHLO part after connecting, which is usually a sign that the server in question doesn't really want to talk to you (for whatever reason). In your example case there are no actual MX records for the domain, but the class still tries the "default" (RFC 2821). So it tries connecting to port 25 there and succeeds, and the server responding on that port doesn't want to play the whole SMTP dance with you. Generally, one way you could avoid the fatal error is to handle the exception yourself at some point using a try/catch block. Either somewhere in the class itself (and then set that email to false), or just around the parts of code where you're calling |
Thank you so much !! @zytzagoo It's works perfectly with a simple try/catch in $validator->validate(); ! Here's the catch:
|
So what's the solution when you do 1000 emails at once? |
Hi! Thank for the script and apologize me for my bad english.
Its works perfect but in some mails its stuck and stops the loop
email:
[email protected]
debug:
and php error log:
[Sun Oct 23 11:26:18.922931 2016] [:error] [pid 2576] [client ip:65433] PHP Fatal error: Uncaught exception 'SMTP_Validate_Email_Exception_No_Connection' with message 'No connection' in /home/admin/web/XXXX/public_htm$
If you know whats happening I'll be very grateful !
My ip is clean and green light on spamhaus
If you test it and it's works fine for you, there is a way to force that mail to false and dont stop the script/loop? thx!
The text was updated successfully, but these errors were encountered: