Index: lang/strings_english.txt
===================================================================
--- lang/strings_english.txt	(revision 315)
+++ lang/strings_english.txt	(revision 317)
@@ -1300,7 +1300,7 @@
 $s_linked_projects = 'Linked Projects';
 
 $s_custom_field_sequence = 'Sequence';
-$s_custom_field_type_enum_string = '0:String,1:Numeric,2:Float,3:Enumeration,4:E-mail,5:Checkbox,6:List,7:Multiselection list,8:Date,9:Radio';
+$s_custom_field_type_enum_string = '0:String,1:Numeric,2:Float,3:Enumeration,4:E-mail,5:Checkbox,6:List,7:Multiselection list,8:Date,9:Radio,10:User,11:Users multiselection list';
 
 $s_confirm_used_custom_field_deletion = 'This field is currently linked to at least one project. If you continue all values for this field will be permanently deleted. This action cannot be undone. If you do not want to delete this field, hit the Back button in your browser. To proceed, click the button below';
 $s_confirm_custom_field_deletion = 'Are you sure you want to delete this custom field and all associated values?';
Index: lang/strings_french.txt
===================================================================
--- lang/strings_french.txt	(revision 315)
+++ lang/strings_french.txt	(revision 317)
@@ -1088,7 +1088,7 @@
 $s_link_custom_field_to_project_button = 'Lier champ personnalisé';
 $s_linked_projects = 'Projets liés';
 $s_custom_field_sequence = 'Suite';
-$s_custom_field_type_enum_string = '0:Chaîne de caractères,1:Nombre entier,2:Nombre réel,3:Énumération,4:Courriel,5:Case à cocher,6:Liste,7:Liste à sélection multiple,8:Date,9:Bouton radio';
+$s_custom_field_type_enum_string = '0:Chaîne de caractères,1:Nombre entier,2:Nombre réel,3:Énumération,4:Courriel,5:Case à cocher,6:Liste,7:Liste à sélection multiple,8:Date,9:Bouton radio,10:Utilisateur,11:Liste d'utilisateurs';
 $s_confirm_used_custom_field_deletion = 'Ce champ est actuellement lié à au moins un projet.  Si vous continuez, toutes les valeurs de ce champ seront supprimées.  Cette action ne peut être annulée.  Si vous ne voulez pas supprimer ce champ, cliquer sur le bouton Retour de votre navigateur.  Sinon pour supprimer ce champ, cliquer sur le bouton ci dessous';
 $s_confirm_custom_field_deletion = 'Êtes vous sûr de vouloir supprimer ce champ personnalisé et toutes les valeurs associées ?';
 $s_field_delete_button = 'Supprimer le champ';
Index: config_defaults_inc.php
===================================================================
--- config_defaults_inc.php	(revision 315)
+++ config_defaults_inc.php	(revision 317)
@@ -3008,7 +3008,7 @@
 	 *
 	 * @global string $g_custom_field_type_enum_string
 	 */
-	$g_custom_field_type_enum_string    = '0:string,1:numeric,2:float,3:enum,4:email,5:checkbox,6:list,7:multiselection list,8:date,9:radio';
+	$g_custom_field_type_enum_string    = '0:string,1:numeric,2:float,3:enum,4:email,5:checkbox,6:list,7:multiselection list,8:date,9:radio,10:userlist,11:usermultilist';
 
 	/*********************************
 	 * MantisBT Javascript Variables *
Index: core/filter_api.php
===================================================================
--- core/filter_api.php	(revision 315)
+++ core/filter_api.php	(revision 317)
@@ -2988,7 +2988,22 @@
 									$t_values .= $t_start;
 									break;
 							}
-						} else {
+						} elseif( $t_accessible_custom_fields_types[$i] == CUSTOM_FIELD_TYPE_USER_LIST || $t_accessible_custom_fields_types[$i] == CUSTOM_FIELD_TYPE_USER_MULTILIST) {
+							$t_current = $t_filter['custom_fields'][$t_accessible_custom_fields_ids[$i]][0];
+							
+							$t_values .= '<input type="hidden" name="custom_field_' . $t_accessible_custom_fields_ids[$i] . '[]" value="' . $t_current . '" />';
+							
+							if( filter_field_is_any( $t_current ) ) {
+								$t_any_found = true;
+							} else if( filter_field_is_none( $t_current ) ) {
+								$t_this_string = lang_get( 'none' );
+							} else {
+								$t_this_string = user_get_name( $t_current);
+							}
+							
+							$t_output .= $t_this_string;
+							
+						}else{
 							$t_first_flag = true;
 							foreach( $t_filter['custom_fields'][$t_accessible_custom_fields_ids[$i]] as $t_current ) {
 								$t_current = stripslashes( $t_current );
@@ -4002,6 +4017,8 @@
 	} else if( isset( $t_accessible_custom_fields_names[$j] ) ) {
 		if( $t_accessible_custom_fields_types[$j] == CUSTOM_FIELD_TYPE_DATE ) {
 			print_filter_custom_field_date( $j, $p_field_id );
+		} elseif( $t_accessible_custom_fields_types[$j] == CUSTOM_FIELD_TYPE_USER_LIST || $t_accessible_custom_fields_types[$j] == CUSTOM_FIELD_TYPE_USER_MULTILIST ) {
+			print_filter_custom_field_user( $j, $p_field_id );
 		} else {
 			echo '<select ' . $t_select_modifier . ' name="custom_field_' . $p_field_id . '[]">';
 			echo '<option value="' . META_FILTER_ANY . '" ';
@@ -4221,6 +4238,22 @@
 	print "</td></tr>\n</table>";
 }
 
+
+function print_filter_custom_field_user( $p_field_num, $p_field_id ) {
+	global $t_filter, $t_accessible_custom_fields_names, $t_accessible_custom_fields_types, $t_accessible_custom_fields_values, $t_accessible_custom_fields_ids, $t_select_modifier;
+
+		echo '<select name="custom_field_'.$p_field_id.'[]">';
+		 	echo '<option value="' . META_FILTER_ANY . '"';
+			check_selected( $t_filter['custom_fields'][$p_field_id][0], META_FILTER_ANY );
+			echo '>' . lang_get( 'any' ) . '</option>' . "\n";
+			echo '<option value="' . META_FILTER_NONE . '"';
+			check_selected( $t_filter['custom_fields'][$p_field_id][0], META_FILTER_NONE );
+			echo '>' . lang_get( 'none' ) . '</option>' . "\n";
+			
+			print_user_option_list($t_filter['custom_fields'][$p_field_id][0],helper_get_current_project());
+		echo '</select>';
+}
+
 /**
  *  print project field
  */
Index: core/gpc_api.php
===================================================================
--- core/gpc_api.php	(revision 315)
+++ core/gpc_api.php	(revision 317)
@@ -226,6 +226,7 @@
 function gpc_get_custom_field( $p_var_name, $p_custom_field_type, $p_default = null ) {
 	switch( $p_custom_field_type ) {
 		case CUSTOM_FIELD_TYPE_MULTILIST:
+		case CUSTOM_FIELD_TYPE_USER_MULTILIST:
 		case CUSTOM_FIELD_TYPE_CHECKBOX:
 		    // ensure that the default is an array, if set
 		    if ( ($p_default !== null) && !is_array($p_default) ) {
Index: core/cfdefs/cfdef_standard.php
===================================================================
--- core/cfdefs/cfdef_standard.php	(revision 315)
+++ core/cfdefs/cfdef_standard.php	(revision 317)
@@ -158,6 +158,34 @@
 	'#function_string_value_for_email' => 'cfdef_prepare_date_value_for_email',
 );
 
+$g_custom_field_type_definition[ CUSTOM_FIELD_TYPE_USER_LIST ] = array (
+	'#display_possible_values' => FALSE,
+	'#display_valid_regexp' => FALSE,
+	'#display_length_min' => FALSE,
+	'#display_length_max' => FALSE,
+	'#display_default_value' => FALSE,
+	'#function_return_distinct_values' => 'cfdef_prepare_user_list_distinct_values',
+	'#function_value_to_database' => null,
+	'#function_database_to_value' => null,
+	'#function_print_input' => 'cfdef_input_userlist',
+	'#function_string_value' => 'cfdef_prepare_user_list_value',
+	'#function_string_value_for_email' => 'cfdef_prepare_user_database_to_value',
+);
+
+$g_custom_field_type_definition[ CUSTOM_FIELD_TYPE_USER_MULTILIST ] = array (
+	'#display_possible_values' => TRUE,
+	'#display_valid_regexp' => FALSE,
+	'#display_length_min' => FALSE,
+	'#display_length_max' => FALSE,
+	'#display_default_value' => FALSE,
+	'#function_return_distinct_values' => 'cfdef_prepare_user_list_distinct_values',
+	'#function_value_to_database' => 'cfdef_prepare_list_value_to_database',
+	'#function_database_to_value' => null,
+	'#function_print_input' => 'cfdef_input_userlist',
+	'#function_string_value' => 'cfdef_prepare_user_multilist_value',
+	'#function_string_value_for_email' => 'cfdef_prepare_user_multilist_value',
+);
+
 function cfdef_prepare_list_database_to_value($p_value) {
 	return rtrim( ltrim( $p_value, '|' ), '|' );
 }
@@ -256,6 +284,35 @@
 	echo '</select>';
 }
 
+function cfdef_input_userlist($p_field_def, $t_custom_field_value) {	
+	
+	if ( $p_field_def['type'] == CUSTOM_FIELD_TYPE_USER_MULTILIST ) {
+		$t_selected_values = explode( '|', $t_custom_field_value );
+		
+		echo '<select ', helper_get_tab_index(), ' name="custom_field_' . $p_field_def['id'] . '[]" size="' . $t_list_size . '" multiple="multiple">';
+		$t_selected_values = explode( '|', $t_custom_field_value );
+		$t_values = project_get_all_user_rows(helper_get_current_project());
+		$t_list_size = 5;
+		
+		foreach( $t_values as $t_option ) {
+			if( in_array( $t_option['id'], $t_selected_values ) ) {				
+				echo '<option value="' . $t_option['id']  . '" selected="selected">' . user_get_name( $t_option['id'] ) . '</option>';
+			} else {
+				echo '<option value="' .  $t_option['id'] . '">' . user_get_name( $t_option['id'] ) . '</option>';
+			}
+		}
+	} else {
+		echo '<select ', helper_get_tab_index(), ' name="custom_field_' . $p_field_def['id'] . '">';
+		print_user_option_list($t_custom_field_value);
+	}
+		
+	
+	
+	
+	echo '</select>';
+	
+}
+
 function cfdef_input_checkbox($p_field_def, $t_custom_field_value) {
 	$t_values = explode( '|', custom_field_prepare_possible_values( $p_field_def['possible_values'] ) );
 	$t_checked_values = explode( '|', $t_custom_field_value );
@@ -342,3 +399,29 @@
 	}
 	return $t_return_arr;
 }
+
+
+function cfdef_prepare_user_list_value($p_value){
+	return user_get_name($p_value);
+}
+
+
+function cfdef_prepare_user_multilist_value($p_value){
+	$t_userlist = explode('|',$p_value);
+	$t_return = array();
+	foreach($t_userlist as $t_user){
+		if(user_exists($t_user)){
+			$t_return[] = user_get_name($t_user);
+		}
+	}
+	return implode(', ',$t_return);
+}
+
+function cfdef_prepare_user_list_distinct_values($p_field_def){
+	$t_values = project_get_all_user_rows(helper_get_current_project());
+	$t_return = array();
+	foreach( $t_values as $t_option ) {
+		$t_return[$t_option['id']] = user_get_name($t_option['id']);
+	}
+	return $t_return;
+}
Index: core/custom_field_api.php
===================================================================
--- core/custom_field_api.php	(revision 315)
+++ core/custom_field_api.php	(revision 317)
@@ -44,15 +44,17 @@
 #	- add functions to return individual db columns for a field definition
 # *******************************************
 
-$g_custom_field_types[CUSTOM_FIELD_TYPE_STRING] = 'standard';
-$g_custom_field_types[CUSTOM_FIELD_TYPE_NUMERIC] = 'standard';
-$g_custom_field_types[CUSTOM_FIELD_TYPE_FLOAT] = 'standard';
-$g_custom_field_types[CUSTOM_FIELD_TYPE_ENUM] = 'standard';
-$g_custom_field_types[CUSTOM_FIELD_TYPE_EMAIL] = 'standard';
-$g_custom_field_types[CUSTOM_FIELD_TYPE_CHECKBOX] = 'standard';
-$g_custom_field_types[CUSTOM_FIELD_TYPE_LIST] = 'standard';
-$g_custom_field_types[CUSTOM_FIELD_TYPE_MULTILIST] = 'standard';
-$g_custom_field_types[CUSTOM_FIELD_TYPE_DATE] = 'standard';
+$g_custom_field_types[CUSTOM_FIELD_TYPE_STRING] 	= 'standard';
+$g_custom_field_types[CUSTOM_FIELD_TYPE_NUMERIC] 	= 'standard';
+$g_custom_field_types[CUSTOM_FIELD_TYPE_FLOAT] 		= 'standard';
+$g_custom_field_types[CUSTOM_FIELD_TYPE_ENUM] 		= 'standard';
+$g_custom_field_types[CUSTOM_FIELD_TYPE_EMAIL] 		= 'standard';
+$g_custom_field_types[CUSTOM_FIELD_TYPE_CHECKBOX] 	= 'standard';
+$g_custom_field_types[CUSTOM_FIELD_TYPE_LIST] 		= 'standard';
+$g_custom_field_types[CUSTOM_FIELD_TYPE_MULTILIST] 	= 'standard';
+$g_custom_field_types[CUSTOM_FIELD_TYPE_DATE] 		= 'standard';
+$g_custom_field_types[CUSTOM_FIELD_TYPE_USER_LIST]	= 'standard';
+$g_custom_field_types[CUSTOM_FIELD_TYPE_USER_MULTILIST]	= 'standard';
 
 foreach( $g_custom_field_types as $type ) {
 	require_once( 'cfdefs' . DIRECTORY_SEPARATOR . 'cfdef_' . $type . '.php' );
@@ -1226,6 +1228,11 @@
 				$t_valid &= email_is_valid( $p_value );
 			}
 			break;
+		case CUSTOM_FIELD_TYPE_USER:
+			if ( $p_value !== '' ) {
+				$t_valid &= email_is_valid( $p_value );
+			}
+			break;
 		default:
 			break;
 	}
Index: core/constant_inc.php
===================================================================
--- core/constant_inc.php	(revision 315)
+++ core/constant_inc.php	(revision 317)
@@ -421,6 +421,8 @@
 define( 'CUSTOM_FIELD_TYPE_MULTILIST', 7 );
 define( 'CUSTOM_FIELD_TYPE_DATE', 8 );
 define( 'CUSTOM_FIELD_TYPE_RADIO', 9 );
+define( 'CUSTOM_FIELD_TYPE_USER_LIST', 10 );
+define( 'CUSTOM_FIELD_TYPE_USER_MULTILIST', 11 );
 
 # Meta filter values
 define( 'META_FILTER_MYSELF', -1 );
