This article describes how to use the disable_functions directive in a custom php.ini file to disable specific functions.
For security reasons, you may want to disable certain PHP functions. For example, the exec and system functions are particularly dangerous when they are used with unsanitized input values.
To disable a function, use a text editor to modify the disable_functions directive in the php.ini file. This directive takes a comma-delimited list. For example, to disable the exec and system functions, use the following directive:
disable_functions = "exec, system"
If you want to re-enable the functions, modify the disable_functions directive in the php.ini file as follows:
disable_functions = ""
Subscribe to receive weekly cutting edge tips, strategies, and news you need to grow your web business.
No charge. Unsubscribe anytime.