Browse files

MDL-27171 forum: refactor forum settings

Signed-off-by: Ruslan Kabalin <ruslan.kabalin@luns.net.uk>
  • Loading branch information...
1 parent 2f2137f commit e710658d8969e27b9406ee9ab2635f989ff26336 Ruslan Kabalin committed May 12, 2011
Showing with 6 additions and 7 deletions.
  1. +6 −7 mod/forum/settings.php
View
13 mod/forum/settings.php
@@ -65,18 +65,17 @@
$settings->add(new admin_setting_configcheckbox('forum_usermarksread', get_string('usermarksread', 'forum'),
get_string('configusermarksread', 'forum'), 0));
- // Default time (hour) to execute 'clean_read_records' cron
$options = array();
- for ($i=0; $i<24; $i++) {
- $options[$i] = $i;
+ for ($i = 0; $i < 24; $i++) {
+ $options[$i] = sprintf("%02d",$i);
}
+ // Default time (hour) to execute 'clean_read_records' cron
$settings->add(new admin_setting_configselect('forum_cleanreadtime', get_string('cleanreadtime', 'forum'),
get_string('configcleanreadtime', 'forum'), 2, $options));
- for ($i = 0; $i < 23; $i++) {
- $options[$i] = sprintf("%02d",$i);
- }
- $settings->add(new admin_setting_configselect('digestmailtime', get_string('digestmailtime', 'forum'), get_string('configdigestmailtime', 'forum'), 17, $options));
+ // Default time (hour) to send digest email
+ $settings->add(new admin_setting_configselect('digestmailtime', get_string('digestmailtime', 'forum'),
+ get_string('configdigestmailtime', 'forum'), 17, $options));
if (empty($CFG->enablerssfeeds)) {
$options = array(0 => get_string('rssglobaldisabled', 'admin'));

0 comments on commit e710658

Please sign in to comment.