My email service stops accepting email several times a day which causes this error “Fatal error: Uncaught exception ‘Swift_TransportException’ with message …”.
Is their a way I can catch it inside the code and handle it?
Ed
[QUOTE=emilner;37224]My email service stops accepting email several times a day which causes this error “Fatal error: Uncaught exception ‘Swift_TransportException’ with message …”.
Is their a way I can catch it inside the code and handle it?
Ed[/QUOTE]
I tried it once to catch the issue with ‘try… catch’ around the mail instruction, but somehow this is not triggered on an email issue. So if there’s a way, I don’t know it. I guess the error is on a too low level.
Hi, I’m having the same problem. The error is simple, the password that the user gives is not correct so connection to mail server is failed.
I need some validation, if email and password are correct, then proceed to sc_mail_send, if not, just display some error message.
Can it be done?
Thank you
yes it can be done, but then you need to login to the smtp server and log out again.
I suggets using phpmailer (which is better then the scriptcase mailer anyway).
You can custom code it but the smtp user/password are coming from the php.ini file and thus it is not favorable to use.
A basic example is quickly found: http://phpmailer.worxware.com/?pg=examplebsmtp and http://stackoverflow.com/questions/14256582/phpmailer-smtp-configuration