23                 $a_user_image = 
false, $a_profile_link = 
false, $a_profile_back_link = 
"",
 
   24                 $a_force_first_lastname = 
false)
 
   28                 if (!($return_as_array = is_array($a_user_id)))
 
   29                         $a_user_id = array($a_user_id);
 
   42                                                         a.usr_id = b.usr_id AND 
   44                                 WHERE ' . $ilDB->in(
'a.usr_id', $a_user_id, 
false, 
'integer');
 
   46                 $userrow = $ilDB->queryF($sql, array(
'text'), array(
'public_profile'));
 
   50                 while (
$row = $ilDB->fetchObject($userrow))
 
   52                         if ($a_force_first_lastname ||
 
   53                                 $has_public_profile = in_array(
$row->public_profile, array(
"y", 
"g")))
 
   55                                 $pres = 
$row->lastname.
", ".(
$t = 
$row->title ? 
$t . 
" " : 
"").
$row->firstname.
" ";
 
   58                         $pres.= 
"[".$row->login.
"]";
 
   60                         if ($a_profile_link && $has_public_profile)
 
   62                                 $ilCtrl->setParameterByClass(
"ilpublicuserprofilegui", 
"user", 
$row->usr_id);
 
   63                                 if ($a_profile_back_link != 
"")
 
   65                                         $ilCtrl->setParameterByClass(
"ilpublicuserprofilegui", 
"back_url",
 
   66                                                 rawurlencode($a_profile_back_link));
 
   68                                 $pres = 
'<a href="'.$ilCtrl->getLinkTargetByClass(
"ilpublicuserprofilegui", 
"getHTML").
'">'.$pres.
'</a>';
 
   74                                 $pres = 
'<img border="0" src="'.$img.
'" alt="'.$lng->txt(
"icon").
 
   75                                         " ".$lng->txt(
"user_picture").
'" /> '.$pres;
 
   78                         $names[
$row->usr_id] = $pres; 
 
   81                 foreach($a_user_id as $id)
 
   84                                 $names[$id] = 
"unknown";
 
   87                 return $return_as_array ? $names : $names[$a_user_id[0]];