Excellent! The more one can avoid changing the Moodle code, the better because then one doesn't need to worry when doing an upgrade.
Not one page, but each the Moodle settings documentation pages. If you take a look at the Moodle config-dist.php configuration template file, you'll see that apart from the settings regarding the database, etc., at the section "OTHER MISCELLANEOUS SETTINGS" it says that the section in question is about the "additional tweaks for which no GUI exists in Moodle yet."
That means that in the config.php file one may also enter any directive that can be set via the Moodle GUI. To do that, one should:
- Go to the related Moodle setting page.
- Look for setting one wants to enter at the config.php file.
- Take note of the related keyword and the values it accepts.
- And then, at the config.php fle add a line like so:
$CFG-keyword = value;
For example, let's assume that one needs to enable debugging via the config.php file. If one checks the Debugging settings page:
Administration > Development > Debugging
one may see that the keyword for the parameter "Display debug messages" is debugdisplay and that its possible values are "No" --the default-- and "Yes". With this information one may then open the config.php file and add the following line:
$CFG->debugdisplay = Yes;
Note 1. Given that it is a boolean value, one may enter any of the following to enable: 1, On, True, Yes; and any of the following to disable: 0, Off, False, No. For example, the following would also work:
$CFG->debugdisplay = true;
Note 2. In this particular case, one would actually need to also add a few other lines, as shown in the section "SETTINGS FOR DEVELOPMENT SERVERS" of the config-dist.php file.
As a quick second example, consider wanting to disable the "Cache all language strings":
Administration > Language > Language settings
As the keyword for that directive is langstringcache and that its values are Yes and No, one should then only need to add the following line to the config.php file:
$CFG->langstringcache = No;
or any of the values to disable mentioned in the previous Note 1, like:
$CFG->langstringcache = false;