[SOLVED] Mail Error Line when Error triggers

Need help installing PHP, configuring a script, or configuring a server? Then come on in and post your questions! We'll try to help the best we can!

Moderator: General Moderators

Post Reply
User avatar
anjanesh
DevNet Resident
Posts: 1679
Joined: Sat Dec 06, 2003 9:52 pm
Location: Mumbai, India

[SOLVED] Mail Error Line when Error triggers

Post by anjanesh »

Hi

I've used log_errors to log all errors to a file and display_errors Off to not to display them.

Is there any way a mail can be sent when a error gets triggered ?
What I want is two-fold - write error to error log file and mail the same line.

Thanks
Last edited by anjanesh on Thu Aug 04, 2005 10:57 pm, edited 1 time in total.
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

User avatar
Ambush Commander
DevNet Master
Posts: 3698
Joined: Mon Oct 25, 2004 9:29 pm
Location: New Jersey, US

Post by Ambush Commander »

I've actually done some reading about this. It's generally not recommended because when errors do happen, they tend to happen in spurts, so you'll end up getting lots of emails before you're able to turn of the handle. Make sure you apply some intelligent limiting before you do this.
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

the errors can be pooled and using a shutdown function, can then send any errors in one email.
User avatar
Ambush Commander
DevNet Master
Posts: 3698
Joined: Mon Oct 25, 2004 9:29 pm
Location: New Jersey, US

Post by Ambush Commander »

My point exactly. :)
User avatar
anjanesh
DevNet Resident
Posts: 1679
Joined: Sat Dec 06, 2003 9:52 pm
Location: Mumbai, India

Post by anjanesh »

Once again - thanks Feyd !
Post Reply