search
HomeBackend DevelopmentPHP ProblemHow to display error message in php

How to display error message in php

Nov 02, 2020 am 11:57 AM
phpError message

How to display error information in php: 1. Use a text editor to open the php.ini configuration file; 2. Add the code [ini_set("display_errors", "stderr");error_reporting(E_ALL);]; 3. Restart the server.

How to display error message in php

Specific method:

(Video tutorial recommendation: php video tutorial)

Use first Open the php configuration file in the editor

My php installation directory is /usr/local/php

vim /usr/local/php/etc/php.ini

Then add the following lines of code at the head of the php configuration file

ini_set("display_errors", "stderr");  //ini_set函数作用:为一个配置选项设置值,
error_reporting(E_ALL);     //显示所有的错误信息

Finally restart the server.

Related recommendations: php training

The above is the detailed content of How to display error message in php. 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

Hot AI Tools

Undress AI Tool

Undress AI Tool

Undress images for free

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

VSCode Windows 64-bit Download

VSCode Windows 64-bit Download

A free and powerful IDE editor launched by Microsoft

SublimeText3 English version

SublimeText3 English version

Recommended: Win version, supports code prompts!

ZendStudio 13.5.1 Mac

ZendStudio 13.5.1 Mac

Powerful PHP integrated development environment

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

EditPlus Chinese cracked version

EditPlus Chinese cracked version

Small size, syntax highlighting, does not support code prompt function