ini_alter

string ini_alter(string name, string value) 

Alters the value of a PHP configuration option.

Returns:

Previous value of setting; FALSE on error

Description:

Alter the value of a PHP configuration option. This is not a permanent change and exists only for the lifetime of the script calling the function. This is an alias for ini_set().

Version:

Existing since version 4.0

Example:

Alter the value of magic_quotes_gpc
$option = 'magic_quotes_gpc'; 
echo "Value of $option => ", ini_get($option); 
ini_alter($option,0); 
echo "New value of $option => ", ini_get($option); 

Get PHP Functions Essential Reference now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.