Web development and examples of PHP, jQuery, HTML5, WordPress, MySQL & AMP


How to display PHP errors at runtime with a simple code

Many servers do not display PHP errors by default, so many times when not getting the expected result or performance we don´t know which line of code is giving error.

With the following functions placed at the beginning of our PHP files we will show the PHP errors:

Additionally I put more example code to show or not to display the errors of PHP:

Cookie Policy

This website uses cookies to provide you with the best user experience. If you continue to browsing you are consenting to the acceptance of these cookies and acceptance of our cookie policy, click the link for more information.

ACCEPT
Aviso de cookies