wp config set <name> <value>
Sets the value of a specific constant or variable defined in wp-config.php file
Arguments
Name | Description |
---|
name | Name of the wp-config.php constant or variable |
value | Value to set the wp-config.php constant or variable to |
Options
Name | Description |
---|
--add | Add the value if it doesn’t exist yet. This is the default behavior, override with –no-add |
--no-add | Add the value if it doesn’t exist yet. This is the default behavior, override with –no-add |
--raw | Place the value into the wp-config.php file as is, instead of as a quoted string |
--anchor <anchor> | Anchor string where additions of new values are anchored around. Defaults to “/* That’s all, stop editing!” |
--placement <options> | Where to place the new values in relation to the anchor string |
--separator <separator> | Separator string to put between an added value and its anchor string. The following escape sequences will be recognized and properly interpreted: ‘
’ => newline, ‘
’ => carriage return, ‘ ’ => tab. Defaults to a single EOL (“
” on *nix and “
” on Windows) |
--type <options> | Type of the config value to set. Defaults to ‘all’ |