[svn r18898] Minor - Fixes correct user name (partial FS#3751)

skala
Julio Montoya 17 years ago
parent d308f31ad3
commit bff21fa21e
  1. 2
      main/social/contacts.inc.php
  2. 8
      main/social/group_contact.inc.php
  3. 55
      main/social/qualify_contact.inc.php
  4. 32
      main/social/show_search_image.inc.php

@ -28,7 +28,7 @@ $image_path = UserManager::get_user_picture_path_by_id ($user_id,'web',false,tru
echo '  Dokeos  -  ';
$user_id=api_get_user_id();
$user_info=api_get_user_info($user_id);
echo $user_info['firstName'].'  '.$user_info['lastName'];
echo $name_user=mb_convert_encoding($user_info['firstName'].' '.$user_info['lastName'],'UTF-8',$charset) ;
?></td>
</tr>
</table>

@ -18,6 +18,7 @@ $list_groups=array();
<?php
$user_id=api_get_user_id();
$list_groups=UserFriend::show_list_type_friends();
for ($p=0;$p<count($list_groups);$p++) {
$list_path_friends=UserFriend::get_list_path_web_by_user_id ($user_id,$list_groups[$p]['id']);
?>
@ -60,14 +61,15 @@ if (count($list_path_friends)!=0) {
}
while ($j<$number_of_images) {
if ($list_friends_file[$j]<>"") {
$user_info=api_get_user_info($list_friends_id[$j]);
$name_user=$user_info['firstName'].' '.$user_info['lastName'];
$user_info=api_get_user_info($list_friends_id[$j]);
$user_name=mb_convert_encoding($user_info['firstName'].' '.$user_info['lastName'],'UTF-8',$charset) ;
if($list_friends_file[$j]==='unknown.jpg') {
$big='';
} else {
$big='big_';
}
$friend_html.='&nbsp;<div class="image-social-content" id=div_'.$list_friends_id[$j].' style="float:left" ><a href="javascript:void(0)" onclick=load_thick("'.$list_friends_dir[$j].$big.$list_friends_file[$j].'","'.urlencode($name_user).'") title="" class="thickbox"><img src="'.$list_friends_dir[$j].$list_friends_file[$j].'" width="90" height="110" style="margin-left:3px ;margin-rigth:3px;margin-top:10px;margin-bottom:3px;" id="imgfriend_'.$list_friends_id[$j].'" title="'.$name_user.'" /></a></div>&nbsp;';
$friend_html.='&nbsp;<div class="image-social-content" id=div_'.$list_friends_id[$j].' style="float:left;height:150px;" ><a href="javascript:void(0)" onclick=load_thick("'.$list_friends_dir[$j].$big.$list_friends_file[$j].'","") title="" class="thickbox">' .
'<img src="'.$list_friends_dir[$j].$list_friends_file[$j].'" width="90" height="110" style="margin-left:3px ;margin-rigth:3px;margin-top:10px;margin-bottom:3px;" id="imgfriend_'.$list_friends_id[$j].'" title="'.$user_name.'" />'.$user_name.'</a></div>&nbsp;';
}
$j++;
}

@ -1,4 +1,26 @@
<?php
<?php
/*
==============================================================================
Dokeos - elearning and course management software
Copyright (c) 2009 Dokeos SPRL
Copyright (c) Julio Montoya Armas
For a full list of contributors, see "credits.txt".
The full license can be read in "license.txt".
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.
See the GNU General Public License for more details.
Contact address: Dokeos, rue du Corbeau, 108, B-1030 Brussels, Belgium
Mail: info@dokeos.com
==============================================================================
*/
$language_file=array('registration','messages','userInfo','admin');
require_once '../inc/global.inc.php';
require_once (api_get_path(LIBRARY_PATH).'usermanager.lib.php');
@ -27,27 +49,30 @@ $user_friend_relation=UserFriend::get_relation_between_contacts(api_get_user_id(
<table width="600" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="600" align="left">
<td width="50%"><br/>
<img style="float:left" src="<?php echo $img_user[1]; ?>" />
<td width="50%"><br/>
<img src="<?php echo $img_user[1]; ?>" />
<?php
echo '<br /><br />'.$name_user=mb_convert_encoding($user_info['firstName'].' '.$user_info['lastName'],'UTF-8',$charset) ;
?>
</td>
<td width="50%"><div align="left">
<?php
for ($k=0;$k<$number_list;$k++) {
echo '<br/>';
if ($list_of_options[$k]['id']==$user_friend_relation) {
echo '<br/>';
if ($list_of_options[$k]['id']==$user_friend_relation) {
$check='checked="checked"';
} else {
} else {
$check='';
}
?>
}
?>
<input <?php echo $check; ?> style="margin-left:50px" type="radio" class="radio" name="list_type_friend" value="<?php echo $list_of_options[$k]['id']; ?>" />
<?php
echo mb_convert_encoding(get_lang($list_of_options[$k]['title']),'UTF-8',$charset);
echo '<br/>';
?>
<?php
}
<input <?php echo $check; ?> style="margin-left:50px" type="radio" class="radio" name="list_type_friend" value="<?php echo $list_of_options[$k]['id']; ?>" />
<?php
echo mb_convert_encoding(get_lang($list_of_options[$k]['title']),'UTF-8',$charset);
echo '<br/>';
?>
<?php
}
echo '<br/>';
?>
<input style="margin-left:50px" type="button" value="<?php echo mb_convert_encoding(get_lang('AttachToGroup'),'UTF-8',$charset); ?>" onclick="set_qualify_friend()"/>

@ -1,4 +1,26 @@
<?php
/*
==============================================================================
Dokeos - elearning and course management software
Copyright (c) 2009 Dokeos SPRL
Copyright (c) Julio Montoya Armas
For a full list of contributors, see "credits.txt".
The full license can be read in "license.txt".
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.
See the GNU General Public License for more details.
Contact address: Dokeos, rue du Corbeau, 108, B-1030 Brussels, Belgium
Mail: info@dokeos.com
==============================================================================
*/
$cidReset = true;
require '../inc/global.inc.php';
$language_file = array('registration','messages','userInfo','admin');
@ -41,13 +63,13 @@ if (count($list_path_friends)!=0) {
while ($j<$number_of_images) {
if ($list_friends_file[$j]<>"") {
$user_info=api_get_user_info($list_friends_id[$j]);
$name_user=$user_info['firstName'].' '.$user_info['lastName'];
$user_name=mb_convert_encoding($user_info['firstName'].' '.$user_info['lastName'],'UTF-8',$charset) ;
/*$friend_html.='&nbsp;<div onMouseover="show_icon_delete(this)" onMouseout="hide_icon_delete(this)" class="image-social-content" id=div_'.$list_friends_id[$j].' style="float:left" >
<img src="'.$list_friends_dir[$j]."/".$list_friends_file[$j].'" width="90" height="110" style="margin-left:3px ;margin-rigth:3px;margin-top:10px;margin-bottom:3px;" id="imgfriend_'.$list_friends_id[$j].'" title="'.$name_user.'" onclick="qualify_friend(this)"/>
<img src="'.$list_friends_dir[$j]."/".$list_friends_file[$j].'" width="90" height="110" style="margin-left:3px ;margin-rigth:3px;margin-top:10px;margin-bottom:3px;" id="imgfriend_'.$list_friends_id[$j].'" title="'.$user_name.'" onclick="qualify_friend(this)"/>
<img onclick="delete_friend (this)" id=img_'.$list_friends_id[$j].' src="../img/blank.gif" alt="" title="" class="image-delete" /></div>&nbsp;'; */
$friend_html.='&nbsp;<div onMouseover="show_icon_delete(this)" onMouseout="hide_icon_delete(this)" class="image-social-content" id=div_'.$list_friends_id[$j].' style="float:left" >
<img src="'.$list_friends_dir[$j].$list_friends_file[$j].'" width="90" height="110" style="margin-left:3px ;margin-rigth:3px;margin-top:10px;margin-bottom:3px;" id="imgfriend_'.$list_friends_id[$j].'" title="'.$name_user.'" onclick=load_thick(\'qualify_contact.inc.php?path_user="'.urlencode($list_friends_dir[$j].$list_friends_file[$j]).'&amp;id_user="'.$list_friends_id[$j].'"\',"'.urlencode($name_user).'") />
<img onclick="delete_friend (this)" id=img_'.$list_friends_id[$j].' src="../img/blank.gif" alt="" title="" class="image-delete" /></div>&nbsp;';
$friend_html.='&nbsp;<div onMouseover="show_icon_delete(this)" onMouseout="hide_icon_delete(this)" class="image-social-content" id=div_'.$list_friends_id[$j].' style="height:150px;float:left" >
<img src="'.$list_friends_dir[$j].$list_friends_file[$j].'" width="90" height="110" style="margin-left:3px ;margin-rigth:3px;margin-top:10px;margin-bottom:3px;" id="imgfriend_'.$list_friends_id[$j].'" title="'.$user_name.'" onclick=load_thick(\'qualify_contact.inc.php?path_user="'.urlencode($list_friends_dir[$j].$list_friends_file[$j]).'&amp;id_user="'.$list_friends_id[$j].'"\',"") />
<img onclick="delete_friend (this)" id=img_'.$list_friends_id[$j].' src="../img/blank.gif" alt="" title="" class="image-delete" /> '.$user_name.'</div>&nbsp;';
}
$j++;
}

Loading…
Cancel
Save