2 This file is part of Moodle - http://moodle.org/
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.
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/>.
18 @template core_admin/setting
20 Admin setting template.
22 Context variables required for this template:
23 * labelfor - id of the form element
24 * title - Setting title
25 * override - Overridden message
26 * warning - Warning message
28 * error - Error message
29 * element - The Element HTML
30 * forceltr - Force this element to be displayed LTR
31 * default - Default value
33 Example context (json):
35 "title": "Setting title",
37 "override": "Overidden",
41 "element": "Raw HTML",
43 "default": "Default value"
46 <div class="form-item clearfix" id="{{id}}">
47 <div class="form-label">
48 <label {{#labelfor}}for="{{labelfor}}"{{/labelfor}}>
51 <div class="form-overridden">{{override}}</div>
54 <div class="form-warning">{{warning}}</div>
57 <span class="form-shortname">{{{name}}}</span>
59 <div class="form-setting">
61 <div><span class="error">{{error}}</span></div>
65 <div class="form-defaultinfo {{#forceltr}}text-ltr{{/forceltr}}">{{{default}}}</div>
68 <div class="form-description">{{{description}}}</div>