Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

MDL-23534 Added setting to set the site pages node to the sites short…

…name if desired
  • Loading branch information...
commit 016ba63816d7321c44acb46620d1fafa34063c21 1 parent 5d2db8a
@samhemelryk samhemelryk authored
View
1  admin/settings/appearance.php
@@ -92,6 +92,7 @@
$temp->add(new admin_setting_configcheckbox('navshowallcourses', get_string('navshowallcourses', 'admin'), get_string('confignavshowallcourses', 'admin'), 0));
$temp->add(new admin_setting_configtext('navcourselimit',get_string('navcourselimit','admin'),get_string('confignavcourselimit', 'admin'),20,PARAM_INT));
$temp->add(new admin_setting_configcheckbox('navlinkcoursesections', get_string('navlinkcoursesections', 'admin'), get_string('navlinkcoursesections_help', 'admin'), 0));
+ $temp->add(new admin_setting_configcheckbox('usesitenameforsitepages', get_string('usesitenameforsitepages', 'admin'), get_string('configusesitenameforsitepages', 'admin'), 0));
$ADMIN->add('appearance', $temp);
View
2  lang/en/admin.php
@@ -345,6 +345,7 @@
$string['configunzip'] = 'Indicate the location of your unzip program (Unix only, optional). If specified, this will be used to unpack zip archives on the server. If you leave this blank, then Moodle will use internal routines.';
$string['configuseblogassociations'] = 'Should users be able to organize their blog by associating entries with courses and course modules?';
$string['configuseexternalyui'] = 'Instead of using local files, use online files available on Yahoo‘s servers. WARNING: This requires an internet connection, or no AJAX will work on your site.';
+$string['configusesitenameforsitepages'] = 'If enabled the site\'s shortname will be used for the site pages node in the navigation rather than the string \'Site pages\'';
$string['configusetags'] = 'Should tags functionality across the site be enabled?';
$string['configvariables'] = 'Variables';
$string['configverifychangedemail'] = 'Enables verification of changed email addresses using allowed and denied email domains settings. If this setting is disabled the domains are enforced only when creating new users.';
@@ -1067,6 +1068,7 @@
$string['usersupdated'] = 'Users updated';
$string['usersweakpassword'] = 'Users having a weak password';
$string['userquota'] = 'User quota';
+$string['usesitenameforsitepages'] = 'Use site name for site pages';
$string['usetags'] = 'Enable tags functionality';
$string['uubulk'] = 'Select for bulk operations';
$string['uubulkall'] = 'All users';
View
4 lib/navigationlib.php
@@ -2155,7 +2155,9 @@ public function add_course(stdClass $course, $forcegeneric = false, $ismycourse
if ($issite) {
$parent = $this;
$url = null;
- $shortname = get_string('sitepages');
+ if (empty($CFG->usesitenameforsitepages)) {
+ $shortname = get_string('sitepages');
+ }
} else if ($ismycourse) {
$parent = $this->rootnodes['mycourses'];
$url = new moodle_url('/course/view.php', array('id'=>$course->id));
Please sign in to comment.
Something went wrong with that request. Please try again.