BuddyDev

Search

Friends Suggestion Pro

  • Participant
    Level: Initiated
    Posts: 2
    Alexander Sugianto on #37158

    Hi,
    I have added the user profile fields using WBCOM user profile Pro. But the fields are not reflected in the suggestion rules.

    How else to add user profile fields that can be used for Friends Suggestion?

  • Keymaster
    (BuddyDev Team)
    Posts: 24623
    Brajesh Singh on #37251

    Hi Alexander,
    I am sorry for the delayed reply.

    we are not doing anything special to exclude any field.

    here is the code that we are using to create the fields list in the dropdown.

    
    
    	static $profile_fields = array();
    
    	if ( ! empty( $profile_fields ) ) {
    		return $profile_fields;
    	}
    
    	$groups = bp_xprofile_get_groups(
    		array(
    			'hide_empty_groups' => true,
    			'fetch_fields'      => true,
    		)
    	);
    
    	foreach ( $groups as $group ) {
    		foreach ( $group->fields as $field ) {
    			$profile_fields[ $field->id ] = $field->name;
    		}
    	}
    
    	return $profile_fields;
    

    Please contact WBCOM and ask them if they are excluding their fields from non edit/signup pages. It is quite possible that their plugin is excluding some fields on non signup/edit profile screens.

    Regards
    Brajesh

You must be logged in to reply to this topic.

This topic is: not resolved