Configuration reference – administration settings
Each parameter in the Site administration menus can be configured via config.php
. If a value has been set via this method, it is effectively hardcoded and cannot be changed via the Moodle interface, not even by the administrator.
For example, you might want to ensure that an administrator does not turn on HTTPS for logins on an internal site, even by accident. Activating this would lock everybody out of the site if no SSL certificate is installed. To do this, enter the following line in config.php
:
$CFG->loginhttps=false;
How do you know what the parameter is called? Go to the respective setting in Moodle (in this case, Site administration | Security | HTTP security), and you will see the parameter’s name underneath the label.
Tip
You can search for any parameter in the search box of the administration menu.
If the value is specified in config.php
, Moodle will display Defined in config.php beside the...