php hide ALL errors

前端 未结 5 2193
自闭症患者
自闭症患者 2020-12-01 03:57

what are the best practises for hiding all php errors? As I don\'t want ERRORS to show to the user.

I\'ve tried using the .htacess by p

5条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-12-01 04:06

    In your php file just enter this code:

    error_reporting(0);
    

    This will report no errors to the user. If you somehow want, then just comment this.

提交回复
热议问题