Page 1 of 1

PHP Error reporting

Posted: Mon Apr 12, 2010 9:43 am
by echofool
For some reason my error reporting doesn't display on the screen any more it just stores them in my error logs...It used to always display an error for any type of mistake now i just get white screens....
I put :

Code: Select all

<?php
session_start();
require_once($_SERVER['DOCUMENT_ROOT']."/../css/includes/bconnect45/errorreporter.php"); 
In my global header so all pages have the error reporter yet it doesn't work! This is what is in my error reporter script:

Code: Select all

<?php
ini_set('display_errors',1);
error_reporting(E_ALL | E_STRICT | E_RECOVERABLE_ERROR | E_DEPRECATED | E_USER_DEPRECATED);
?>
any idea what i got wrong ? :S

Re: PHP Error reporting

Posted: Mon Apr 12, 2010 9:53 am
by pickle
Setting error reporting to just E_ALL should suffice.

Re: PHP Error reporting

Posted: Mon Apr 12, 2010 10:11 am
by echofool
So removing the strict part will make it work ?

Re: PHP Error reporting

Posted: Mon Apr 12, 2010 10:28 am
by pickle
Everything but the E_ALL - try it.

Re: PHP Error reporting

Posted: Mon Apr 12, 2010 10:56 pm
by echofool
Hmm, no i still get white screens =/

Re: PHP Error reporting

Posted: Tue Apr 13, 2010 8:39 am
by solid
From php.net:
Note: Although display_errors may be set at runtime (with ini_set()), it won't have any affect if the script has fatal errors. This is because the desired runtime action does not get executed.
If you have Fatal Errors being logged, then this is why they are not being displayed.

Re: PHP Error reporting

Posted: Tue Apr 13, 2010 10:28 am
by echofool
Can fatal errors be displayed ? They store in my error_logs file - some im wondering if theres some way to do it?

Hope you can help.