For those who use [php_man]error_reporting[/php_man], I'm interested in what setting you use for this function. I would use E_STRICT, but it shows notices for using 'var' in front of setting variables inside a class, so I end up using E_ALL.
Also, please specify why.
php error reporting... which one do you use?
Moderator: General Moderators
Re: php error reporting... which one do you use?
I'm still on php4 for most of my deployment target (webhosts), so I develop using E_ALL on php4, and when deploying (production), I leave it to the server default (which is usually E_ERROR only or similar).phice wrote:For those who use [php_man]error_reporting[/php_man], I'm interested in what setting you use for this function. I would use E_STRICT, but it shows notices for using 'var' in front of setting variables inside a class, so I end up using E_ALL.
Also, please specify why.
I have one test host running php5, (dotgeek rules!), but even there, I dont use E_STRICT.. its just not realistic.
-
The Monkey
- Forum Contributor
- Posts: 168
- Joined: Tue Mar 09, 2004 9:05 am
- Location: Arkansas, USA
When developing, I leave it on E_ALL; then when I consider the project "done" and the users come in, I set it to E_NONE and use error_log to record any errors in a directory unaccessable to my users.
I couple that with plenty of return FALSE checks in my query functions, so if something goes wrong, I can provide a custom error message to my user, and let the script continue on it's way. Works great.
- Monkey
I couple that with plenty of return FALSE checks in my query functions, so if something goes wrong, I can provide a custom error message to my user, and let the script continue on it's way. Works great.
- Monkey
