Home > Article > Backend Development > How to disable method in php.ini
How to disable php.ini: 1. Find and open the php.ini configuration file; 2. Find the "disable_functions" option and use this option to turn off some dangerous functions.
The operating environment of this article: Windows 7 system, PHP version 7.1, Dell G3 computer.
php.ini How to disable methods?
Disable PHP functions, you can configure php.ini
There is a disable_functions switch option in php.ini, this option can turn off some dangerous functions , such as system, exec, etc.
For example: disable_functions = phpinfo, if the phpinfo() function is called in the file, then when error_reporting is turned on, the following error will be prompted:
Warning: phpinfo() has been disabled for security reasons
Shielded function example:
disable_functions= phpinfo,dl, exec, system
Recommended learning: "PHP Video Tutorial"
The above is the detailed content of How to disable method in php.ini. For more information, please follow other related articles on the PHP Chinese website!