Sobes.tech
Junior — Middle

What effect does using the -d option in a command or script have?

sobes.tech AI

Answer from AI

The -d option in PHP is used to enable or set configuration directives (php.ini) directly from the command line when running a script.

For example, the command:

php -d memory_limit=512M script.php

sets the memory limit for script execution to 512 megabytes, overriding the value from php.ini.

This is convenient for temporarily changing settings without editing configuration files, for example, for debugging or running scripts with special requirements.

What effect does using the -d option in a command or… - sobes.tech