Helping ordinary people create extraordinary websites!
   

How to show all errors in PHP?

Monday, 4th October 2010
by Guest

Hi,
The PHP page I am working on will not show me any errors in the code but I know that there must be errors as I am not getting my desired output or any output at all. How do I make the page show me any errors my code is producing.

- Jesse.





HappyCoder
There are 2 ways you can set your error level in PHP. Your first option is to change the value of "error_reporting" directive from your php.ini file to "E_ALL" (this means you have acces control to your webserver config files). The second option is to change your error reporting level directly in your php file by using the following instruction:
ini_set('error_reporting', E_ALL);

This second option changes your error reporting level temporary as opposed to the first option that changes the error reporting level for all the php scripts.
Monday, 11th October 2010
Votes:
19
9

More PHP Help:
» What is PHP?
» How to check server report after each 5 minutes
» How to select and display a set of images from a folder using PHP?
» What is Polymorphism in PHP?
» How to strip the querystring from a URL using PHP?
» How to destroy PHP cookie?
» Splash screen
» How to get database values in table format on form?

SPREAD THE WORD!
Tell a Friend

GET OUR NEWS


Developer Resources