mirror of
https://github.com/moodle/moodle.git
synced 2025-04-25 10:26:17 +02:00
Merge branch 'MDL-61573-master' of https://github.com/Kathrin84/moodle
This commit is contained in:
commit
bac1731614
@ -32,9 +32,9 @@ if ($hassiteconfig or has_any_capability($capabilities, $systemcontext)) { // sp
|
||||
'customusermenuitems',
|
||||
new lang_string('customusermenuitems', 'admin'),
|
||||
new lang_string('configcustomusermenuitems', 'admin'),
|
||||
'grades,grades|/grade/report/mygrades.php|grades
|
||||
messages,message|/message/index.php|message
|
||||
preferences,moodle|/user/preferences.php|preferences',
|
||||
'grades,grades|/grade/report/mygrades.php|t/grades
|
||||
messages,message|/message/index.php|t/message
|
||||
preferences,moodle|/user/preferences.php|t/preferences',
|
||||
PARAM_RAW,
|
||||
'50',
|
||||
'10'
|
||||
|
@ -192,7 +192,7 @@ Moodle community|https://moodle.org
|
||||
-Moodle development|https://moodle.org/development
|
||||
Moodle.com|http://moodle.com/
|
||||
</pre>';
|
||||
$string['configcustomusermenuitems'] = 'You can configure the contents of the user menu (with the exception of the log out link, which is automatically added). Each line is separated by pipe characters and consists of 1) a string in "langstringname, componentname" form or as plain text, 2) a URL, and 3) an icon either as a pix icon (in the folder pix/t, or prefix the icon name with ../ if icon is in another pix folder) or as a URL. Dividers can be used by adding a line of one or more # characters where desired.';
|
||||
$string['configcustomusermenuitems'] = 'You can configure the contents of the user menu (with the exception of the log out link, which is automatically added). Each line is separated by pipe characters and consists of 1) a string in "langstringname, componentname" form or as plain text, 2) a URL, and 3) an icon either as a pix icon (in the folder pix with the structure [subfoldername]/[iconname], e.g. i/publish) or as a URL. Dividers can be used by adding a line of one or more # characters where desired.';
|
||||
$string['configdbsessions'] = 'If enabled, this setting will use the database to store information about current sessions. Note that changing this setting now will log out all current users (including you). If you are using MySQL please make sure that \'max_allowed_packet\' in my.cnf (or my.ini) is at least 4M. Other session drivers can be configured directly in config.php, see config-dist.php for more information. This option disappears if you specify session driver in config.php file.';
|
||||
$string['configdebug'] = 'If you turn this on, then PHP\'s error_reporting will be increased so that more warnings are printed. This is only useful for developers.';
|
||||
$string['configdebugdisplay'] = 'Set to on, the error reporting will go to the HTML page. This is practical, but breaks XHTML, JS, cookies and HTTP headers in general. Set to off, it will send the output to your server logs, allowing better debugging. The PHP setting error_log controls which log this goes to.';
|
||||
|
12
user/lib.php
12
user/lib.php
@ -753,7 +753,17 @@ function user_convert_text_to_menu_items($text, $page) {
|
||||
$child->pix = $pixpath;
|
||||
} else {
|
||||
// Check for the specified image existing.
|
||||
$pixpath = "t/" . $bits[2];
|
||||
if (strpos($bits[2], '../') === 0) {
|
||||
// The string starts with '../'.
|
||||
// Strip off the first three characters - this should be the pix path.
|
||||
$pixpath = substr($bits[2], 3);
|
||||
} else if (strpos($bits[2], '/') === false) {
|
||||
// There is no / in the path. Prefix it with 't/', which is the default path.
|
||||
$pixpath = "t/{$bits[2]}";
|
||||
} else {
|
||||
// There is a '/' in the path - this is either a URL, or a standard pix path with no changes required.
|
||||
$pixpath = $bits[2];
|
||||
}
|
||||
if ($page->theme->resolve_image_location($pixpath, 'moodle', true)) {
|
||||
// Use the image.
|
||||
$child->pix = $pixpath;
|
||||
|
Loading…
x
Reference in New Issue
Block a user