Merge branch 'wip-MDL-36108-master' of git://github.com/phalacee/moodle

This commit is contained in:
Dan Poltawski 2012-12-11 16:03:09 +08:00
commit 09f5d8344e

View File

@ -151,12 +151,13 @@ class block_online_users extends block_base {
$timeago = format_time($now - $user->lastaccess); //bruno to calculate correctly on frontpage
if (isguestuser($user)) {
$this->content->text .= '<div class="user">'.$OUTPUT->user_picture($user, array('size'=>16));
$this->content->text .= '<div class="user">'.$OUTPUT->user_picture($user, array('size'=>16, 'alttext'=>false));
$this->content->text .= get_string('guestuser').'</div>';
} else {
$this->content->text .= '<div class="user">'.$OUTPUT->user_picture($user, array('size'=>16));
$this->content->text .= '<a href="'.$CFG->wwwroot.'/user/view.php?id='.$user->id.'&amp;course='.$this->page->course->id.'" title="'.$timeago.'">'.$user->fullname.'</a></div>';
$this->content->text .= '<div class="user">';
$this->content->text .= '<a href="'.$CFG->wwwroot.'/user/view.php?id='.$user->id.'&amp;course='.$this->page->course->id.'" title="'.$timeago.'">';
$this->content->text .= $OUTPUT->user_picture($user, array('size'=>16, 'alttext'=>false, 'link'=>false)) .$user->fullname.'</a></div>';
}
if ($canshowicon and ($USER->id != $user->id) and !isguestuser($user)) { // Only when logged in and messaging active etc
$anchortagcontents = '<img class="iconsmall" src="'.$OUTPUT->pix_url('t/message') . '" alt="'. get_string('messageselectadd') .'" />';