unable to see php errors in browser difficult to debug ....

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
krmkrishnan
Forum Newbie
Posts: 7
Joined: Thu Dec 04, 2008 11:36 pm

unable to see php errors in browser difficult to debug ....

Post by krmkrishnan »

thank for ur help i created pdf file .and one more thing is ,php does not show errors for many mistakes in the code.if i leave any braces ...... like that .then how can i debug...
it shows only plain white page..... wat shud i do???
pls reply
thanks
User avatar
jaoudestudios
DevNet Resident
Posts: 1483
Joined: Wed Jun 18, 2008 8:32 am
Location: Surrey

Re: unable to see php errors in browser difficult to debug ....

Post by jaoudestudios »

Check your apache settings. Errors display should be on. On your development machine set it to show all errors including notices.
User avatar
airy
Forum Newbie
Posts: 20
Joined: Fri Jul 11, 2008 2:53 am

Re: unable to see php errors in browser difficult to debug ....

Post by airy »

add

Code: Select all

error_reporting(E_ALL);
in you code
User avatar
John Cartwright
Site Admin
Posts: 11470
Joined: Tue Dec 23, 2003 2:10 am
Location: Toronto
Contact:

Re: unable to see php errors in browser difficult to debug ....

Post by John Cartwright »

airy wrote:add

Code: Select all

error_reporting(E_ALL);
in you code
Unfortunately this does not affect parse errors, as the code can never compile in the first place. It would need to be set in your apache configuration file, or through .htaccess
User avatar
jaoudestudios
DevNet Resident
Posts: 1483
Joined: Wed Jun 18, 2008 8:32 am
Location: Surrey

Re: unable to see php errors in browser difficult to debug ....

Post by jaoudestudios »

Unfortunately this does not affect parse errors, as the code can never compile in the first place.
Jcart has a good point :D
Post Reply