From: dongsheng Date: Tue, 6 Jan 2009 06:52:53 +0000 (+0000) Subject: "MDL-17747, Add Max category depth as a configuratble setting to the site settings... X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=6bfc7fd579a1a7e01d4e2f9764dabd10c3c5f870;p=moodle.git "MDL-17747, Add Max category depth as a configuratble setting to the site settings, merged from 1.9, credit goes to Jason Hardin" --- diff --git a/admin/settings/frontpage.php b/admin/settings/frontpage.php index 4481d6be1e..aafd5e64b6 100644 --- a/admin/settings/frontpage.php +++ b/admin/settings/frontpage.php @@ -26,6 +26,13 @@ if (get_site()) { //do not use during installation $temp->add(new admin_setting_special_frontpagedesc()); $temp->add(new admin_setting_courselist_frontpage(false)); // non-loggedin version of the setting (that's what the parameter is for :) ) $temp->add(new admin_setting_courselist_frontpage(true)); // loggedin version of the setting + + $options = array(); + for ($i=1; $i<100; $i++) { + $options[$i] = $i; + } + $temp->add(new admin_setting_configselect('max_category_depth', get_string('sitemaxcategorydepth','admin'), get_string('sitemaxcategorydepthhelp','admin'), 50, $options)); + $temp->add(new admin_setting_sitesetcheckbox('numsections', get_string('sitesection'), get_string('sitesectionhelp','admin'), 1)); $temp->add(new admin_setting_sitesetselect('newsitems', get_string('newsitemsnumber'), '', 3, array('0' => '0', diff --git a/lang/en_utf8/admin.php b/lang/en_utf8/admin.php index 5db475b757..96d44d9d44 100644 --- a/lang/en_utf8/admin.php +++ b/lang/en_utf8/admin.php @@ -171,6 +171,8 @@ $string['configlongtimenosee'] = 'If students haven\'t logged in for a very long $string['configlookahead'] = 'Days to look ahead'; $string['configmailnewline'] = 'Newline characters used in mail messages. CRLF is required according to RFC 822bis, some mail servers do automatic conversion from LF to CRLF, other mail servers do incorrect conversion from CRLF to CRCRLF, yet others reject mails with bare LF (qmail for example). Try changing this setting if you are having problems with undelivered emails or double newlines.'; $string['configmaxbytes'] = 'This specifies a maximum size that uploaded files can be throughout the whole site. This setting is limited by the PHP settings post_max_size and upload_max_filesize, as well as the Apache setting LimitRequestBody. In turn, maxbytes limits the range of sizes that can be chosen at course level or module level. If \'Server Limit\' is chosen, the server maximum allowed by the server will be used.'; +$string['sitemaxcategorydepth'] = 'Maximum Category Depth'; +$string['sitemaxcategorydepthhelp'] = 'This specifies the maximum number of child categories shown'; $string['configmaxeditingtime'] = 'This specifies the amount of time people have to re-edit forum postings, glossary comments etc. Usually 30 minutes is a good value.'; $string['configmaxevents'] = 'Events to Lookahead'; $string['configmemcachedhosts'] = 'For memcached. Comma-separated list of hosts that are running the memcached daemon. Use IP addresses to avoid DNS latency. memcached does not behave well if you add/remove hosts on a running setup.';