The example in this article describes a workaround for PHP prompts Warning:phpinfo () has been disabled function disabled. Share to everyone for your reference. The specific analysis is as follows:
Today, a friend of the server test a Web site found that I encountered in the test phpinfo PHP warning:phpinfo () has been disabled for the security reasons prompted, by the words of meaning I summed up the solution, Let's take a look at the next.
When you run phpinfo you are prompted as follows:PHP Warning:phpinfo () has been disabled for security reasons in xx.php on line XX
This passage means to tell us that due to security considerations the Phpinfo () function is disabled, and if you have server administrative privileges, please modify the php.ini profile parameter and restart Apache again.
Open the PHP installation path to open the php.ini file, specific example: in php.ini exist disable_functions configuration, the default configuration, CLI execution function is prohibited, if necessary, in PHP.ini will Disable_ functions = Phpinfo,exec, Popen, system ..., delete the function you need to perform from the list and restart Apache.
Completely a problem with configuration, Linux solution for the edit PHP configuration file:
Vi/usr/local/php/etc/php.ini
Look for the Disable_functions string, the following scandir delete, hint: VI can be entered/, enter the search mode, easy to find disable_functions.
Reboot PHP in effect:
Copy Code code as follows:
/ETC/INIT.D/PHP-FPM restart
I hope this article will help you with your PHP program design.