From 8f6e7e6c12a8450f3c7bcfb856d823a98de4a687 Mon Sep 17 00:00:00 2001 From: nicolasconnault Date: Tue, 18 Aug 2009 05:19:13 +0000 Subject: [PATCH] MDL-19823 Upgraded calls to helpbutton, print_simple_box* and notify --- tag/coursetags_edit.php | 4 ++-- tag/coursetags_more.php | 2 +- tag/coursetagslib.php | 4 ++-- tag/edit.php | 2 +- tag/manage.php | 4 ++-- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/tag/coursetags_edit.php b/tag/coursetags_edit.php index 71e74d9e68..e3435d2a34 100644 --- a/tag/coursetags_edit.php +++ b/tag/coursetags_edit.php @@ -115,7 +115,7 @@ print_header_simple($title, '', $nav, '', '', false); // Print the add and delete form $script = coursetag_get_jscript(); - $addtagshelp = helpbutton('addtags', 'adding tags', $tagslang, TRUE, FALSE, '', TRUE); + $addtagshelp = $OUTPUT->help_icon(moodle_help_icon::make('addtags', 'adding tags', $tagslang)); $edittagthisunit = get_string('edittagthisunit', $tagslang); $arrowtitle = get_string('arrowtitle', $tagslang); $sesskey = sesskey(); @@ -148,7 +148,7 @@ print_header_simple($title, '', $nav, '', '', false); EOT; if ($coursetabs) { - $deletetagshelp = helpbutton('deletetags', 'deleting tags', $tagslang, TRUE, FALSE, '', TRUE); + $deletetagshelp = $OUTPUT->help_icon(moodle_help_icon::make('deletetags', 'deleting tags', $tagslang)); $editdeletemytag = get_string('editdeletemytag', $tagslang); $outstr .= << diff --git a/tag/coursetags_more.php b/tag/coursetags_more.php index 98ae06f2a6..176951f579 100644 --- a/tag/coursetags_more.php +++ b/tag/coursetags_more.php @@ -177,7 +177,7 @@ if (strlen($tags) < 10000) { $fclass = 'coursetag_more_large'; } $outstr = '
'.$welcome. - helpbutton('usingtags', 'using tags', $tagslang, TRUE, FALSE, '', TRUE).' + $OUTPUT->help_icon(moodle_help_icon::make('usingtags', 'using tags', $tagslang)).'
diff --git a/tag/coursetagslib.php b/tag/coursetagslib.php index ce8cf694b9..64066d93f6 100644 --- a/tag/coursetagslib.php +++ b/tag/coursetagslib.php @@ -464,7 +464,7 @@ function coursetag_get_tagged_courses($tagid) { */ function coursetag_delete_course_tags($courseid, $showfeedback=false) { - global $DB; + global $DB, $OUTPUT; if ($tags = $DB->get_records_select('tag_instance', "itemtype='course' AND itemid=:courseid", array('courseid'=>$courseid))) { foreach ($tags as $tag) { @@ -478,7 +478,7 @@ function coursetag_delete_course_tags($courseid, $showfeedback=false) { } if ($showfeedback) { - notify(get_string('deletedcoursetags', 'tag')); + echo $OUTPUT->notification(get_string('deletedcoursetags', 'tag')); } } diff --git a/tag/edit.php b/tag/edit.php index a39a017cff..6010df70cf 100644 --- a/tag/edit.php +++ b/tag/edit.php @@ -119,7 +119,7 @@ print_header_simple(get_string('tag', 'tag') . ' - '. $tagname, '', $navigation) echo $OUTPUT->heading($tagname, 2); if (!empty($errorstring)) { - notify($errorstring); + echo $OUTPUT->notification($errorstring); } $tagform->display(); diff --git a/tag/manage.php b/tag/manage.php index a6bdd1d001..8508f1ef95 100644 --- a/tag/manage.php +++ b/tag/manage.php @@ -137,10 +137,10 @@ switch($action) { echo '
'; if ($err_notice) { - notify($err_notice, 'red'); + echo $OUTPUT->notification($err_notice, 'red'); } if ($notice) { - notify($notice, 'green'); + echo $OUTPUT->notification($notice, 'green'); } // small form to add an official tag -- 2.39.5