Merge branch 'MDL-62896-master' of git://github.com/k-holland/moodle
[moodle.git] / theme / clean / settings.php
blob0f265dbacb80462a039857ab9d4140be1814c0fa
1 <?php
2 // This file is part of Moodle - http://moodle.org/
3 //
4 // Moodle is free software: you can redistribute it and/or modify
5 // it under the terms of the GNU General Public License as published by
6 // the Free Software Foundation, either version 3 of the License, or
7 // (at your option) any later version.
8 //
9 // Moodle is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 // GNU General Public License for more details.
14 // You should have received a copy of the GNU General Public License
15 // along with Moodle. If not, see <http://www.gnu.org/licenses/>.
17 /**
18 * Moodle's Clean theme, an example of how to make a Bootstrap theme
20 * DO NOT MODIFY THIS THEME!
21 * COPY IT FIRST, THEN RENAME THE COPY AND MODIFY IT INSTEAD.
23 * For full information about creating Moodle themes, see:
24 * http://docs.moodle.org/dev/Themes_2.0
26 * @package theme_clean
27 * @copyright 2013 Moodle, moodle.org
28 * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
31 defined('MOODLE_INTERNAL') || die;
33 if ($ADMIN->fulltree) {
35 // Invert Navbar to dark background.
36 $name = 'theme_clean/invert';
37 $title = get_string('invert', 'theme_clean');
38 $description = get_string('invertdesc', 'theme_clean');
39 $setting = new admin_setting_configcheckbox($name, $title, $description, 0);
40 $setting->set_updatedcallback('theme_reset_all_caches');
41 $settings->add($setting);
43 // Logo file setting.
44 $name = 'theme_clean/logo';
45 $title = get_string('logo','theme_clean');
46 $description = get_string('logodesc', 'theme_clean');
47 $setting = new admin_setting_configstoredfile($name, $title, $description, 'logo');
48 $setting->set_updatedcallback('theme_reset_all_caches');
49 $settings->add($setting);
51 // Small logo file setting.
52 $name = 'theme_clean/smalllogo';
53 $title = get_string('smalllogo', 'theme_clean');
54 $description = get_string('smalllogodesc', 'theme_clean');
55 $setting = new admin_setting_configstoredfile($name, $title, $description, 'smalllogo');
56 $setting->set_updatedcallback('theme_reset_all_caches');
57 $settings->add($setting);
59 // Show site name along with small logo.
60 $name = 'theme_clean/sitename';
61 $title = get_string('sitename', 'theme_clean');
62 $description = get_string('sitenamedesc', 'theme_clean');
63 $setting = new admin_setting_configcheckbox($name, $title, $description, 1);
64 $setting->set_updatedcallback('theme_reset_all_caches');
65 $settings->add($setting);
67 // Custom CSS file.
68 $name = 'theme_clean/customcss';
69 $title = get_string('customcss', 'theme_clean');
70 $description = get_string('customcssdesc', 'theme_clean');
71 $default = '';
72 $setting = new admin_setting_configtextarea($name, $title, $description, $default);
73 $setting->set_updatedcallback('theme_reset_all_caches');
74 $settings->add($setting);
76 // Footnote setting.
77 $name = 'theme_clean/footnote';
78 $title = get_string('footnote', 'theme_clean');
79 $description = get_string('footnotedesc', 'theme_clean');
80 $default = '';
81 $setting = new admin_setting_confightmleditor($name, $title, $description, $default);
82 $setting->set_updatedcallback('theme_reset_all_caches');
83 $settings->add($setting);