|
Moodle
2.2.1
http://www.collinsharper.com
|


Public Member Functions | |
| __construct ($name, $visiblename, $description, $defaultsetting) | |
| get_setting () | |
| write_setting ($data) | |
| output_html ($data, $query='') | |
Definition at line 72 of file settingslib.php.
| __construct | ( | $ | name, |
| $ | visiblename, | ||
| $ | description, | ||
| $ | defaultsetting | ||
| ) |
Constructor: uses parent::__construct
| string | $name | unique ascii name, either 'mysetting' for settings that in config, or 'myplugin/mysetting' for ones in config_plugins. |
| string | $visiblename | localised |
| string | $description | long localised info |
| string | $defaultsetting | default value for the setting (actually unused) |
Reimplemented from admin_setting.
Definition at line 82 of file settingslib.php.
| get_setting | ( | ) |
Returns the current setting if it is set
Reimplemented from admin_setting.
Definition at line 91 of file settingslib.php.

| output_html | ( | $ | data, |
| $ | query = '' |
||
| ) |
Returns XHTML field(s) as required by choices
Relies on data being an array should data ever be another valid vartype with acceptable value this may cause a warning/error if (!is_array($data)) would fix the problem
| array | $data | An array of checked values |
| string | $query |
Reimplemented from admin_setting.
Definition at line 141 of file settingslib.php.

| write_setting | ( | $ | data | ) |
Saves the setting(s) provided in $data
| array | $data | An array of data, if not array returns empty str |
Reimplemented from admin_setting.
Definition at line 111 of file settingslib.php.
