mirror of
https://github.com/moodle/moodle.git
synced 2025-03-14 12:40:01 +01:00
Merge branch 'MDL-50469-master' of git://github.com/junpataleta/moodle
This commit is contained in:
commit
dba5826124
@ -839,32 +839,10 @@ function print_container_end($return=false) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Print a bold message in an optional color.
|
||||
*
|
||||
* @deprecated since Moodle 2.0 MDL-19077 - use $OUTPUT->notification instead.
|
||||
* @todo MDL-50469 This will be deleted in Moodle 3.3.
|
||||
* @param string $message The message to print out
|
||||
* @param string $classes Optional style to display message text in
|
||||
* @param string $align Alignment option
|
||||
* @param bool $return whether to return an output string or echo now
|
||||
* @return string|bool Depending on $result
|
||||
*/
|
||||
function notify($message, $classes = 'error', $align = 'center', $return = false) {
|
||||
global $OUTPUT;
|
||||
|
||||
debugging('notify() is deprecated, please use $OUTPUT->notification() instead', DEBUG_DEVELOPER);
|
||||
|
||||
if ($classes == 'green') {
|
||||
debugging('Use of deprecated class name "green" in notify. Please change to "success".', DEBUG_DEVELOPER);
|
||||
$classes = 'success'; // Backward compatible with old color system.
|
||||
}
|
||||
|
||||
$output = $OUTPUT->notification($message, $classes);
|
||||
if ($return) {
|
||||
return $output;
|
||||
} else {
|
||||
echo $output;
|
||||
}
|
||||
function notify() {
|
||||
throw new coding_exception('notify() is removed, please use $OUTPUT->notification() instead');
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -11,6 +11,8 @@ information provided here is intended especially for developers.
|
||||
* Event triggering and event handlers:
|
||||
- The following events, deprecated since moodle 2.6, have been finally removed: groups_members_removed,
|
||||
groups_groupings_groups_removed, groups_groups_deleted, groups_groupings_deleted.
|
||||
* The following functions have been finally deprecated and can not be used any more:
|
||||
- notify()
|
||||
|
||||
=== 3.4 ===
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user