Home >Backend Development >PHP Problem >How to set php not to prompt errors

How to set php not to prompt errors

藏色散人
藏色散人Original
2020-07-29 10:44:073527browse

How to set up php without prompting errors: 1. Use the "error_reporting(E_ALL & ~E_NOTICE)" method directly in the php code; 2. Search for "display_errors = on" in the "php.ini" configuration file and changed to off.

How to set php not to prompt errors

Recommended: "PHP Tutorial"

php settings do not prompt errors

1. Use it directly in the php code:

error_reporting(E_ALL & ~E_NOTICE).

2, or: ini_set("error_reporting","E_ALL & ~E_NOTICE");

3, or search for display_errors = on in the php.ini configuration file and change it to off.

The above is the detailed content of How to set php not to prompt errors. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn