allyc has asked for the wisdom of the Perl Monks concerning the following question:
I am having a problem trapping errors when using Mime::Lite. I am using Mime::Lite in a CGI Script which uses CGI:Carp with fatalsToBrowser turned on.
At the moment, Mime::Lite sends e-mails fine, but if something goes wrong (the biggest example is when Mime::Lite or Net::SMTP can’t connect to the SMTP server. When this happens Mime::Lite croaks.
The problem with this is that when Mime::Lite croaks, fatalsToBrowser is called and the script dies.
Is there any way of turning off this behaviour just when sending messages using Mime::Lite or making Mime::Lite return an error to my script if it can’t connect to the Mail Server?
Any help would be appreciated.
Alistair
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Stopping Module Croaking
by Chady (Priest) on May 11, 2005 at 09:10 UTC | |
|
Re: Stopping Module Croaking
by b10m (Vicar) on May 11, 2005 at 09:24 UTC | |
by gellyfish (Monsignor) on May 11, 2005 at 11:29 UTC | |
|
Re: Stopping Module Croaking
by tlm (Prior) on May 11, 2005 at 10:11 UTC | |
|
Re: Stopping Module Croaking
by thcsoft (Monk) on May 11, 2005 at 12:00 UTC | |
by allyc (Scribe) on May 11, 2005 at 18:29 UTC |