]> git.mjollnir.org Git - moodle.git/commitdiff
"MDL-17747, Add Max category depth as a configuratble setting to the site settings...
authordongsheng <dongsheng>
Tue, 6 Jan 2009 06:52:53 +0000 (06:52 +0000)
committerdongsheng <dongsheng>
Tue, 6 Jan 2009 06:52:53 +0000 (06:52 +0000)
admin/settings/frontpage.php
lang/en_utf8/admin.php

index 4481d6be1e978e5d6307c75028b3300e77ad66e4..aafd5e64b6af9e470f942b405620d19c49b8a10f 100644 (file)
@@ -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',
index 5db475b75733bcf6c7b9d773c9e5f855fdc28e56..96d44d9d44fedccc296eb0ac7f7ddc59e3e6918d 100644 (file)
@@ -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.';