Skip to content

Commit

Permalink
MDL-19818 upgraded calls to print_table, print_single_button, print_u…
Browse files Browse the repository at this point in the history
…ser_picture, print_container* and notice_yesno
  • Loading branch information
nicolasconnault committed Aug 20, 2009
1 parent 7ce73e9 commit 4fa7dc6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion notes/delete.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
$nav[] = array('name' => get_string('notes', 'notes'), 'link' => $CFG->wwwroot . '/notes/index.php?course=' . $course->id . '&user=' . $user->id, 'type' => 'misc');
$nav[] = array('name' => get_string('delete'), 'link' => '', 'type' => 'activity');
print_header($course->shortname . ': ' . $strnotes, $course->fullname, build_navigation($nav));
notice_yesno(get_string('deleteconfirm', 'notes'), 'delete.php', 'index.php', $optionsyes, $optionsno, 'post', 'get');
echo $OUTPUT->confirm(get_string('deleteconfirm', 'notes'), new moodle_url('delete.php',$optionsyes), new moodle_url('index.php',$optionsno));
echo '<br />';
note_print($note, NOTES_SHOW_BODY | NOTES_SHOW_HEAD);
echo $OUTPUT->footer();
Expand Down
4 changes: 2 additions & 2 deletions notes/lib.php
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ function note_get_state_names() {
* @param int $detail OR-ed NOTES_SHOW_xyz flags that specify which note parts to print
*/
function note_print($note, $detail = NOTES_SHOW_FULL) {
global $CFG, $USER, $DB;
global $CFG, $USER, $DB, $OUTPUT;

if (!$user = $DB->get_record('user', array('id'=>$note->userid))) {
debugging("User $note->userid not found");
Expand All @@ -189,7 +189,7 @@ function note_print($note, $detail = NOTES_SHOW_FULL) {
if ($detail & NOTES_SHOW_HEAD) {
echo '<div class="header">';
echo '<div class="user">';
print_user_picture($user, $note->courseid, $user->picture);
echo $OUTPUT->user_picture(moodle_user_picture::make($user, $note->courseid));
echo fullname($user) . '</div>';
echo '<div class="info">' .
get_string('bynameondate', 'notes', $authoring) .
Expand Down

0 comments on commit 4fa7dc6

Please sign in to comment.