PHP
Return PHP version's directives
This function returns the directives in the selected PHP version's php.ini file. WHM's MultiPHP INI Editor interface (Home >> Software >> MultiPHP INI Editor) lists these directives in the Basic Mode section.
Important:
When you disable the Web Server role, the system disables this function.
get/php_ini_get_directives
Query parameters
versionstring required
Example:ea-php74
The name of an installed version of PHP.
- ea-php72
- ea-php73
- ea-php74
- Any custom PHP package name
Response
HTTP Request was successful.
Example response
{
"data": {
"directives": [
{
"default_value": "1",
"info": "This option enables the URL-aware fopen wrappers that enable accessing URL object like files. Default wrappers are provided for the access of remote files using the ftp or http protocol, some extensions like zlib may register additional wrappers.",
"key": "allow_url_fopen",
"php_ini_mode": "PHP_INI_SYSTEM",
"type": "boolean",
"value": "On"
}
]
},
"metadata": {
"command": "php_ini_get_directives",
"reason": "Ok",
"result": 1,
"version": 1
}
}