...

View Full Version : How do you disable warnings in PHP?



PredAlien
09-08-2005, 04:19 PM
hi all,
im new to PHP and i was wondering how i go about disabling warnings in PHP? im using XAMPP with Dreamweaver MX. I was told something about doing it in the config?
many thanks!

devinemke
09-08-2005, 06:05 PM
display_errors = Off
...in your php.ini file. i highly recommend that you don't do this on your development environment as this will nearly impossible to debug your code.

missing-score
09-08-2005, 06:21 PM
You can also use:



error_reporting(0);


at the top of your script.

Personally, I think that if you are new to PHP then you should leave it on... I think everyone should leave it on except on their actual website server... Reason being, if PHP is generating warnings then something could/should be done to stop them happening.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum