


What should I do if PHP cannot display error messages in IIS environment?
Solution to the problem that PHP cannot display the error message in IIS environment: 1. Change the PHP configuration file [php.ini]; 2. Create a new [web.config] file under the root directory of the website and add Corresponding code; 3. Install the component [VCRUNTIME140.dll].
Solution to PHP failing to display error message in IIS environment:
1.PHP
First open the PHP configuration file php.ini and make the following configuration changes:
log_errors = On
html_errors = On
display_errors = On
fastcgi.logging = 0
- ##error_reporting = E_ALL & ~E_NOTICE
Related learning recommendations:can be modified according to your own needs
- # Extension = PHP_CURL.DLL Open the CURL mode
- # EXTENSION = php_opensl.dll. #extension = php_pdo_mysql.dll Open the database transaction processing
- # EXTENSION_DIR = "C: \ PHP \ EXT"; Set the PHP module path .timezone = PRC/ “Asia/Shanghai” ;Set the time zone to China time zone
- short_open_tag = On; cgi.Force_redirect = 0; Open the way to run in CGI. Why not change this item for the time being? # error_reporting = E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED ;Modify the error reminder to the standard mode
2.Web site
- in Create a new web.config file under the root directory of the websiteAdd the following code:
3. Run cmd to enter the directory, and when executing PHP, a pop-up window will prompt: Unable to start this program because VCRUNTIME140.dll is missing from your computer.
- Running php7 under Windows requires Visual C Redistributable 2015. The previous version does not need to be that high. The latest version of Apache may also require this component. This component is a C application created by running Visual Studio 2015. The necessary components can be solved by installing them. You can directly go to the Microsoft official website to download the installation program. Related video recommendations:
- PHP programming from entry to proficiency
<?xml version="1.0" encoding="UTF-8"?> <configuration> <system.web> <compilation debug="true" targetFramework="4.5"/> <httpRuntime targetFramework="4.5"/> </system.web> <system.webServer> <httpErrors errorMode="DetailedLocalOnly" existingResponse="PassThrough"></httpErrors> </system.webServer> </configuration>
The above is the detailed content of What should I do if PHP cannot display error messages in IIS environment?. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

PHP 8.4 brings several new features, security improvements, and performance improvements with healthy amounts of feature deprecations and removals. This guide explains how to install PHP 8.4 or upgrade to PHP 8.4 on Ubuntu, Debian, or their derivati

To work with date and time in cakephp4, we are going to make use of the available FrozenTime class.

To work on file upload we are going to use the form helper. Here, is an example for file upload.

CakePHP is an open-source framework for PHP. It is intended to make developing, deploying and maintaining applications much easier. CakePHP is based on a MVC-like architecture that is both powerful and easy to grasp. Models, Views, and Controllers gu

Visual Studio Code, also known as VS Code, is a free source code editor — or integrated development environment (IDE) — available for all major operating systems. With a large collection of extensions for many programming languages, VS Code can be c

Validator can be created by adding the following two lines in the controller.

CakePHP is an open source MVC framework. It makes developing, deploying and maintaining applications much easier. CakePHP has a number of libraries to reduce the overload of most common tasks.

This tutorial demonstrates how to efficiently process XML documents using PHP. XML (eXtensible Markup Language) is a versatile text-based markup language designed for both human readability and machine parsing. It's commonly used for data storage an
